diff options
| author | Karel Zak <kzak@redhat.com> | 2025-10-14 10:38:07 +0200 |
|---|---|---|
| committer | Karel Zak <kzak@redhat.com> | 2025-10-14 10:38:07 +0200 |
| commit | c97ca5ec1ca964c81378a8ac85aa9b117b117b09 (patch) | |
| tree | b516538b4ca7cf2be1d52db7b5389321b82a1940 /include/c.h | |
| parent | 3610933be25b0a13a2b4409056dc58fb9bf063d8 (diff) | |
| parent | 92b82b9a0f2de981ff84097b9fe4be912f16218c (diff) | |
| download | util-linux-c97ca5ec1ca964c81378a8ac85aa9b117b117b09.tar.gz | |
Merge branch 'feat/add_usage_list_cols_option_macro' of https://github.com/cgoesche/util-linux-fork
* 'feat/add_usage_list_cols_option_macro' of https://github.com/cgoesche/util-linux-fork:
treewide: consolidate --list-columns option in usage() to USAGE_LIST_COLUMNS_OPTION()
include/c.h: add USAGE_LIST_COLUMNS_OPTION() macro
Diffstat (limited to 'include/c.h')
| -rw-r--r-- | include/c.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/c.h b/include/c.h index c4c73ce9df..f7cd08fd8b 100644 --- a/include/c.h +++ b/include/c.h @@ -516,8 +516,13 @@ static inline void __attribute__((__noreturn__)) ul_sig_err(int excode, const ch #define USAGE_DEFAULT_COLUMNS _("\nDefault columns:\n") #define USAGE_SEPARATOR "\n" -#define USAGE_OPTSTR_HELP _("display this help") -#define USAGE_OPTSTR_VERSION _("display version") +#define USAGE_OPTSTR_LIST_COLUMNS _("list the available columns") +#define USAGE_OPTSTR_HELP _("display this help") +#define USAGE_OPTSTR_VERSION _("display version") + +#define USAGE_LIST_COLUMNS_OPTION(marg_dsc) \ + "%-" #marg_dsc "s%s\n" \ + , " -H, --list-columns", USAGE_OPTSTR_LIST_COLUMNS #define USAGE_HELP_OPTIONS(marg_dsc) \ "%-" #marg_dsc "s%s\n" \ |
