systemctl: rework message suggesting how to create a new unit file

We need to specifiy --full for creating full unit files.

Also, this is an explanatory hint, hence shouldn't be logged on LOG_ERR
level.
This commit is contained in:
Lennart Poettering
2018-11-29 11:25:32 +01:00
parent df79fdab21
commit 85163756da
+4 -4
View File
@@ -6952,10 +6952,10 @@ static int find_paths_to_edit(sd_bus *bus, char **names, char ***paths) {
assert(!path);
if (!arg_force) {
log_error("Run 'systemctl edit%s --force %s' to create a new unit.",
arg_scope == UNIT_FILE_GLOBAL ? " --global" :
arg_scope == UNIT_FILE_USER ? " --user" : "",
*name);
log_info("Run 'systemctl edit%s --force --full %s' to create a new unit.",
arg_scope == UNIT_FILE_GLOBAL ? " --global" :
arg_scope == UNIT_FILE_USER ? " --user" : "",
*name);
return -ENOENT;
}