Customisable backup directory.

This commit is contained in:
Your Name
2025-04-25 23:52:08 +12:00
parent 3c99ad1503
commit fa7236b4f5
7 changed files with 51 additions and 17 deletions

View File

@ -29,7 +29,7 @@ void print_help() {
std::cout << std::endl;
std::cout << "Service commands: (if no service is specified, all services for the server are affected)" << std::endl;
std::cout << " install SERVER [SERVICE] Install/reinstall/update service(s). Non-destructive." << std::endl;
std::cout << " edit SERVER [SERVICE] Edit the configuration of the server/service." << std::endl;
std::cout << " edit [SERVER] [SERVICE] Edit the configuration of dropshell/server/service." << std::endl;
std::cout << " COMMAND SERVER [SERVICE] Run a command on service(s)." << std::endl;
std::cout << std::endl;
std::cout << "Standard commands: install, uninstall, backup, restore, start, stop" << std::endl;
@ -237,11 +237,9 @@ int main(int argc, char* argv[]) {
if (cmd == "edit" && argc < 4) {
if (argc < 3)
{
std::cerr << "Error: edit requires a server name and optionally service name" << std::endl;
return 1;
}
dropshell::edit_server(argv[2]);
dropshell::edit_file(dropshell::get_local_dropshell_config_path(), "Please ensure any directories you have introduced in the config file exist.");
else
dropshell::edit_server(argv[2]);
return 0;
}