static int help(void) {
- printf("%s [options]\n\n"
+ printf("%s [OPTIONS...] {COMMAND} ...\n\n"
"Install init system units.\n\n"
" -h --help Show this help\n"
" --force Override existing links\n"
" --system Install into system\n"
" --session Install into session\n"
- " --global Install into all sessions\n"
+ " --global Install into all sessions\n\n"
"Commands:\n"
" enable [NAME...] Enable one or more units\n"
" disable [NAME...] Disable one or more units\n"
}
if (optind >= argc) {
- log_error("Missing verb.");
+ help();
return -EINVAL;
}
else if (streq(argv[optind], "test"))
arg_action = ACTION_TEST;
else {
- log_error("Unknown verb %s", argv[optind]);
+ log_error("Unknown verb %s.", argv[optind]);
return -EINVAL;
}
goto finish;
}
- if ((r = lookup_paths_init(&paths, arg_where == WHERE_SYSTEM ? MANAGER_INIT : MANAGER_SESSION)) < 0) {
+ if ((r = lookup_paths_init(&paths, arg_where == WHERE_SYSTEM ? MANAGER_SYSTEM : MANAGER_SESSION)) < 0) {
log_error("Failed to determine lookup paths: %s", strerror(-r));
goto finish;
}