]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
options: add common option macros for --no-ask-password, --host, --machine
authorZbigniew Jędrzejewski-Szmek <zbyszek@amutable.com>
Tue, 24 Mar 2026 08:49:24 +0000 (09:49 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@amutable.com>
Thu, 26 Mar 2026 09:31:23 +0000 (10:31 +0100)
Co-developed-by: Claude <claude@anthropic.com>
src/shared/options.h

index b86a728794d9dc9ad4c040cb96d8b88fd96379ff..6baec72b4feaffbb1579f644c176077d93fb8a93 100644 (file)
@@ -60,6 +60,12 @@ typedef struct Option {
         OPTION_LONG("cat-config", NULL, "Show configuration files")
 #define OPTION_COMMON_TLDR \
         OPTION_LONG("tldr", NULL, "Show non-comment parts of configuration")
+#define OPTION_COMMON_NO_ASK_PASSWORD \
+        OPTION_LONG("no-ask-password", NULL, "Do not prompt for password")
+#define OPTION_COMMON_HOST \
+        OPTION('H', "host", "[USER@]HOST", "Operate on remote host")
+#define OPTION_COMMON_MACHINE \
+        OPTION('M', "machine", "CONTAINER", "Operate on local container")
 #define OPTION_COMMON_JSON \
         OPTION_LONG("json", "FORMAT", "Generate JSON output (pretty, short, or off)")