cleanup
This commit is contained in:
parent
cfe240397f
commit
2e34b4030a
@ -6,8 +6,7 @@
|
||||
namespace monitarr {
|
||||
struct app_config;
|
||||
|
||||
[[nodiscard]] auto run_cmd(const app_config &cfg, std::string_view cfg_file)
|
||||
-> int;
|
||||
[[nodiscard]] auto run_cmd(const app_config &cfg) -> int;
|
||||
} // namespace monitarr
|
||||
|
||||
#endif // LIBMONITARR_INCLUDE_RUN_CMD_HPP_
|
||||
|
@ -52,7 +52,7 @@ auto main(int argc, char **argv) -> int {
|
||||
} else if (has_arg("-l", argc, argv)) {
|
||||
ret = list_cmd(argc, argv, cfg);
|
||||
} else if (has_arg("-r", argc, argv)) {
|
||||
ret = run_cmd(cfg, cfg_file);
|
||||
ret = run_cmd(cfg);
|
||||
} else if (has_arg("-s", argc, argv)) {
|
||||
ret = show_cmd(argc, argv, cfg);
|
||||
} else {
|
||||
|
@ -133,7 +133,7 @@ static void check_server(const server_cfg &server, data_db &state_db) {
|
||||
return state_db;
|
||||
}
|
||||
|
||||
auto run_cmd(const app_config &cfg, std::string_view cfg_file) -> int {
|
||||
auto run_cmd(const app_config &cfg) -> int {
|
||||
MONITARR_USES_FUNCTION_NAME();
|
||||
auto ret{0};
|
||||
std::signal(SIGINT, quit_handler);
|
||||
|
Loading…
x
Reference in New Issue
Block a user