Skip to content

Commit

Permalink
core: create help method
Browse files Browse the repository at this point in the history
  • Loading branch information
LOSEARDES77 committed Feb 27, 2024
1 parent e931d85 commit 9f987a7
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
#include "config/ConfigManager.hpp"
#include "core/hyprlock.hpp"

void help(){
std::cout << "Usage: hyprlock [options]\n\n"
"Options:\n"
" -v, --verbose - Enable verbose logging\n"
" -q, --quiet - Disable logging\n"
" -d, --display (display) - Specify the Wayland display to connect to\n"
" -h, --help - Show this help message\n";
}
int main(int argc, char** argv, char** envp) {
std::string wlDisplay;

Expand All @@ -19,12 +27,7 @@ int main(int argc, char** argv, char** envp) {
i++;
}
else if (arg == "--help" || arg == "-h") {
std::cout << "Usage: hyprlock [options]\n\n"
"Options:\n"
" -v, --verbose - Enable verbose logging\n"
" -q, --quiet - Disable logging\n"
" -d, --display (display) - Specify the Wayland display to connect to\n"
" -h, --help - Show this help message\n";
help();
return 0;
}
}
Expand Down

0 comments on commit 9f987a7

Please sign in to comment.