summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bash-completion/findmnt1
-rw-r--r--bash-completion/losetup1
-rw-r--r--bash-completion/lscpu1
-rw-r--r--bash-completion/lslocks1
-rwxr-xr-xbash-completion/lslogins1
-rw-r--r--bash-completion/lsmem1
-rw-r--r--bash-completion/lsns1
-rw-r--r--bash-completion/partx1
-rw-r--r--bash-completion/rfkill1
-rw-r--r--bash-completion/swapon1
-rw-r--r--bash-completion/zramctl1
-rw-r--r--disk-utils/partx.83
-rw-r--r--disk-utils/partx.c9
-rw-r--r--login-utils/lslogins.13
-rw-r--r--login-utils/lslogins.c7
-rw-r--r--misc-utils/findmnt.85
-rw-r--r--misc-utils/findmnt.c12
-rw-r--r--misc-utils/lslocks.83
-rw-r--r--misc-utils/lslocks.c9
-rw-r--r--sys-utils/losetup.83
-rw-r--r--sys-utils/losetup.c9
-rw-r--r--sys-utils/lscpu.14
-rw-r--r--sys-utils/lscpu.c11
-rw-r--r--sys-utils/lsmem.13
-rw-r--r--sys-utils/lsmem.c9
-rw-r--r--sys-utils/lsns.83
-rw-r--r--sys-utils/lsns.c9
-rw-r--r--sys-utils/rfkill.83
-rw-r--r--sys-utils/rfkill.c12
-rw-r--r--sys-utils/swapon.83
-rw-r--r--sys-utils/swapon.c8
-rw-r--r--sys-utils/zramctl.83
-rw-r--r--sys-utils/zramctl.c11
33 files changed, 146 insertions, 7 deletions
diff --git a/bash-completion/findmnt b/bash-completion/findmnt
index bdfa5de5c..21167ca30 100644
--- a/bash-completion/findmnt
+++ b/bash-completion/findmnt
@@ -118,6 +118,7 @@ _findmnt_module()
--notruncate
--options
--output
+ --output-all
--pairs
--raw
--types
diff --git a/bash-completion/losetup b/bash-completion/losetup
index b58d8de94..d20726533 100644
--- a/bash-completion/losetup
+++ b/bash-completion/losetup
@@ -63,6 +63,7 @@ _losetup_module()
--list
--noheadings
--output
+ --output-all
--raw
--help
--version"
diff --git a/bash-completion/lscpu b/bash-completion/lscpu
index 69337acef..4d3582fd4 100644
--- a/bash-completion/lscpu
+++ b/bash-completion/lscpu
@@ -37,6 +37,7 @@ _lscpu_module()
--sysroot
--hex
--physical
+ --output-all
--help
--version"
COMPREPLY=( $(compgen -W "${OPTS_ALL[*]}" -- $cur) )
diff --git a/bash-completion/lslocks b/bash-completion/lslocks
index acc7b1ff6..fbe75fffa 100644
--- a/bash-completion/lslocks
+++ b/bash-completion/lslocks
@@ -36,6 +36,7 @@ _lslocks_module()
--noinaccessible
--noheadings
--output
+ --output-all
--pid
--raw
--notruncate
diff --git a/bash-completion/lslogins b/bash-completion/lslogins
index 795b5d848..8651fe9df 100755
--- a/bash-completion/lslogins
+++ b/bash-completion/lslogins
@@ -59,6 +59,7 @@ _lslogins_module()
--noheadings
--notruncate
--output
+ --output-all
--pwd
--raw
--system-accs
diff --git a/bash-completion/lsmem b/bash-completion/lsmem
index 9aa124569..7d6e84247 100644
--- a/bash-completion/lsmem
+++ b/bash-completion/lsmem
@@ -40,6 +40,7 @@ _lsmem_module()
--bytes
--noheadings
--output
+ --output-all
--raw
--sysroot
--summary
diff --git a/bash-completion/lsns b/bash-completion/lsns
index 035f43b2a..8964606cb 100644
--- a/bash-completion/lsns
+++ b/bash-completion/lsns
@@ -40,6 +40,7 @@ _lsns_module()
--list
--noheadings
--output
+ --output-all
--task
--raw
--notruncate
diff --git a/bash-completion/partx b/bash-completion/partx
index 2368336ed..028146b0f 100644
--- a/bash-completion/partx
+++ b/bash-completion/partx
@@ -45,6 +45,7 @@ _partx_module()
--noheadings
--nr
--output
+ --output-all
--pairs
--raw
--sector-size
diff --git a/bash-completion/rfkill b/bash-completion/rfkill
index 2d561e955..4643666e2 100644
--- a/bash-completion/rfkill
+++ b/bash-completion/rfkill
@@ -36,6 +36,7 @@ _rfkill_module()
--json
--noheadings
--output
+ --output-all
--raw
--help
--version
diff --git a/bash-completion/swapon b/bash-completion/swapon
index 4a53ec5ac..f5136efd3 100644
--- a/bash-completion/swapon
+++ b/bash-completion/swapon
@@ -50,6 +50,7 @@ _swapon_module()
--priority
--summary
--show
+ --output-all
--noheadings
--raw
--bytes
diff --git a/bash-completion/zramctl b/bash-completion/zramctl
index 31e3c76a6..5274a561e 100644
--- a/bash-completion/zramctl
+++ b/bash-completion/zramctl
@@ -41,6 +41,7 @@ _zramctl_module()
--find
--noheadings
--output
+ --output-all
--raw
--reset
--size
diff --git a/disk-utils/partx.8 b/disk-utils/partx.8
index af7313cb9..7794f41c9 100644
--- a/disk-utils/partx.8
+++ b/disk-utils/partx.8
@@ -106,6 +106,9 @@ or
.B \-\-list
options.
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.BR \-P , " \-\-pairs"
List the partitions using the KEY="value" format.
.TP
diff --git a/disk-utils/partx.c b/disk-utils/partx.c
index 43a6448db..3ccd1afad 100644
--- a/disk-utils/partx.c
+++ b/disk-utils/partx.c
@@ -765,6 +765,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -g, --noheadings don't print headings for --show\n"), out);
fputs(_(" -n, --nr <n:m> specify the range of partitions (e.g. --nr 2:4)\n"), out);
fputs(_(" -o, --output <list> define which output columns to use\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" -P, --pairs use key=\"value\" output format\n"), out);
fputs(_(" -r, --raw use raw output format\n"), out);
fputs(_(" -S, --sector-size <num> overwrite sector size\n"), out);
@@ -796,7 +797,8 @@ int main(int argc, char **argv)
unsigned int sector_size = 0;
enum {
- OPT_LIST_TYPES = CHAR_MAX + 1
+ OPT_LIST_TYPES = CHAR_MAX + 1,
+ OPT_OUTPUT_ALL
};
static const struct option long_opts[] = {
{ "bytes", no_argument, NULL, 'b' },
@@ -811,6 +813,7 @@ int main(int argc, char **argv)
{ "list-types", no_argument, NULL, OPT_LIST_TYPES },
{ "nr", required_argument, NULL, 'n' },
{ "output", required_argument, NULL, 'o' },
+ { "output-all", no_argument, NULL, OPT_OUTPUT_ALL },
{ "pairs", no_argument, NULL, 'P' },
{ "sector-size",required_argument, NULL, 'S' },
{ "help", no_argument, NULL, 'h' },
@@ -858,6 +861,10 @@ int main(int argc, char **argv)
case 'o':
outarg = optarg;
break;
+ case OPT_OUTPUT_ALL:
+ for (ncolumns = 0; ncolumns < ARRAY_SIZE(infos); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 'P':
scols_flags |= PARTX_EXPORT;
what = ACT_SHOW;
diff --git a/login-utils/lslogins.1 b/login-utils/lslogins.1
index bd6955f82..b56bd57f0 100644
--- a/login-utils/lslogins.1
+++ b/login-utils/lslogins.1
@@ -67,6 +67,9 @@ Don't truncate output.
.TP
\fB\-o\fR, \fB\-\-output \fIlist\fP
Specify which output columns to print. Use
+.TP
+.B \-\-output\-all
+Output all available columns.
.B \-\-help
to get a list of all supported columns.
.TP
diff --git a/login-utils/lslogins.c b/login-utils/lslogins.c
index 51033b01b..727b1d65b 100644
--- a/login-utils/lslogins.c
+++ b/login-utils/lslogins.c
@@ -1241,6 +1241,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" --noheadings don't print headings\n"), out);
fputs(_(" --notruncate don't truncate output\n"), out);
fputs(_(" -o, --output[=<list>] define the columns to output\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" -p, --pwd display information related to login by password.\n"), out);
fputs(_(" -r, --raw display in raw mode\n"), out);
fputs(_(" -s, --system-accs display system accounts\n"), out);
@@ -1277,6 +1278,7 @@ int main(int argc, char *argv[])
OPT_NOTRUNC,
OPT_NOHEAD,
OPT_TIME_FMT,
+ OPT_OUTPUT_ALL,
};
static const struct option longopts[] = {
@@ -1292,6 +1294,7 @@ int main(int argc, char *argv[])
{ "notruncate", no_argument, 0, OPT_NOTRUNC },
{ "noheadings", no_argument, 0, OPT_NOHEAD },
{ "output", required_argument, 0, 'o' },
+ { "output-all", no_argument, 0, OPT_OUTPUT_ALL },
{ "last", no_argument, 0, 'L', },
{ "raw", no_argument, 0, 'r' },
{ "system-accs", no_argument, 0, 's' },
@@ -1385,6 +1388,10 @@ int main(int argc, char *argv[])
return EXIT_FAILURE;
opt_o = 1;
break;
+ case OPT_OUTPUT_ALL:
+ for (ncolumns = 0; (size_t)ncolumns < ARRAY_SIZE(coldescs); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 'r':
outmode = OUT_RAW;
break;
diff --git a/misc-utils/findmnt.8 b/misc-utils/findmnt.8
index 58dd38625..d76d06e9d 100644
--- a/misc-utils/findmnt.8
+++ b/misc-utils/findmnt.8
@@ -150,6 +150,11 @@ options are not specified.
The default list of columns may be extended if \fIlist\fP is
specified in the format \fI+list\fP (e.g. \fBfindmnt \-o +PROPAGATION\fP).
.TP
+.B \-\-output\-all
+Output almost all available columns. The columns that require
+.B \-\-poll
+are not included.
+.TP
.BR \-P , " \-\-pairs"
Use key="value" output format. All potentially unsafe characters are hex-escaped (\\x<code>).
.TP
diff --git a/misc-utils/findmnt.c b/misc-utils/findmnt.c
index 4d55cde33..c3365534c 100644
--- a/misc-utils/findmnt.c
+++ b/misc-utils/findmnt.c
@@ -1227,6 +1227,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -n, --noheadings don't print column headings\n"), out);
fputs(_(" -O, --options <list> limit the set of filesystems by mount options\n"), out);
fputs(_(" -o, --output <list> the output columns to be shown\n"), out);
+ fputs(_(" --output-all output all available columns\n"), out);
fputs(_(" -P, --pairs use key=\"value\" output format\n"), out);
fputs(_(" -R, --submounts print all submounts for the matching filesystems\n"), out);
fputs(_(" -r, --raw use raw output format\n"), out);
@@ -1272,7 +1273,8 @@ int main(int argc, char *argv[])
enum {
FINDMNT_OPT_VERBOSE = CHAR_MAX + 1,
- FINDMNT_OPT_TREE
+ FINDMNT_OPT_TREE,
+ FINDMNT_OPT_OUTPUT_ALL
};
static const struct option longopts[] = {
@@ -1296,6 +1298,7 @@ int main(int argc, char *argv[])
{ "notruncate", no_argument, NULL, 'u' },
{ "options", required_argument, NULL, 'O' },
{ "output", required_argument, NULL, 'o' },
+ { "output-all", no_argument, NULL, FINDMNT_OPT_OUTPUT_ALL },
{ "poll", optional_argument, NULL, 'p' },
{ "pairs", no_argument, NULL, 'P' },
{ "raw", no_argument, NULL, 'r' },
@@ -1396,6 +1399,13 @@ int main(int argc, char *argv[])
case 'o':
outarg = optarg;
break;
+ case FINDMNT_OPT_OUTPUT_ALL:
+ for (ncolumns = 0; ncolumns < ARRAY_SIZE(infos); ncolumns++) {
+ if (is_tabdiff_column(ncolumns))
+ continue;
+ columns[ncolumns] = ncolumns;
+ }
+ break;
case 'O':
set_match(COL_OPTIONS, optarg);
break;
diff --git a/misc-utils/lslocks.8 b/misc-utils/lslocks.8
index ba0f44752..40b2cebf6 100644
--- a/misc-utils/lslocks.8
+++ b/misc-utils/lslocks.8
@@ -40,6 +40,9 @@ to get a list of all supported columns.
The default list of columns may be extended if \fIlist\fP is
specified in the format \fI+list\fP (e.g. \fBlslocks -o +BLOCKER\fP).
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.BR \-p , " \-\-pid " \fIpid\fP
Display only the locks held by the process with this \fIpid\fR.
.TP
diff --git a/misc-utils/lslocks.c b/misc-utils/lslocks.c
index 2427006f6..f83fb76f2 100644
--- a/misc-utils/lslocks.c
+++ b/misc-utils/lslocks.c
@@ -536,6 +536,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -i, --noinaccessible ignore locks without read permissions\n"), out);
fputs(_(" -n, --noheadings don't print headings\n"), out);
fputs(_(" -o, --output <list> define which output columns to use\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" -p, --pid <pid> display only locks held by this process\n"), out);
fputs(_(" -r, --raw use the raw output format\n"), out);
fputs(_(" -u, --notruncate don't truncate text in columns\n"), out);
@@ -558,12 +559,16 @@ int main(int argc, char *argv[])
int c, rc = 0;
struct list_head locks;
char *outarg = NULL;
+ enum {
+ OPT_OUTPUT_ALL = CHAR_MAX + 1
+ };
static const struct option long_opts[] = {
{ "bytes", no_argument, NULL, 'b' },
{ "json", no_argument, NULL, 'J' },
{ "pid", required_argument, NULL, 'p' },
{ "help", no_argument, NULL, 'h' },
{ "output", required_argument, NULL, 'o' },
+ { "output-all", no_argument, NULL, OPT_OUTPUT_ALL },
{ "notruncate", no_argument, NULL, 'u' },
{ "version", no_argument, NULL, 'V' },
{ "noheadings", no_argument, NULL, 'n' },
@@ -603,6 +608,10 @@ int main(int argc, char *argv[])
case 'o':
outarg = optarg;
break;
+ case OPT_OUTPUT_ALL:
+ for (ncolumns = 0; ncolumns < ARRAY_SIZE(infos); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 'V':
printf(UTIL_LINUX_VERSION);
return EXIT_SUCCESS;
diff --git a/sys-utils/losetup.8 b/sys-utils/losetup.8
index cdb9ed052..a7e38f4f4 100644
--- a/sys-utils/losetup.8
+++ b/sys-utils/losetup.8
@@ -145,6 +145,9 @@ print info about all devices. See also \fB\-\-output\fP, \fB\-\-noheadings\fP,
Specify the columns that are to be printed for the \fB\-\-list\fP output.
Use \fB\-\-help\fR to get a list of all supported columns.
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.BR \-n , " \-\-noheadings"
Don't print headings for \fB\-\-list\fP output format.
.IP "\fB\-\-raw\fP"
diff --git a/sys-utils/losetup.c b/sys-utils/losetup.c
index 7c9145a88..670bce2e3 100644
--- a/sys-utils/losetup.c
+++ b/sys-utils/losetup.c
@@ -430,6 +430,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -l, --list list info about all or specified (default)\n"), out);
fputs(_(" -n, --noheadings don't print headings for --list output\n"), out);
fputs(_(" -O, --output <cols> specify columns to output for --list\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" --raw use raw --list output format\n"), out);
fputs(USAGE_SEPARATOR, out);
@@ -590,7 +591,8 @@ int main(int argc, char **argv)
OPT_SIZELIMIT = CHAR_MAX + 1,
OPT_SHOW,
OPT_RAW,
- OPT_DIO
+ OPT_DIO,
+ OPT_OUTPUT_ALL
};
static const struct option longopts[] = {
{ "all", no_argument, NULL, 'a' },
@@ -607,6 +609,7 @@ int main(int argc, char **argv)
{ "noheadings", no_argument, NULL, 'n' },
{ "offset", required_argument, NULL, 'o' },
{ "output", required_argument, NULL, 'O' },
+ { "output-all", no_argument, NULL, OPT_OUTPUT_ALL },
{ "sizelimit", required_argument, NULL, OPT_SIZELIMIT },
{ "partscan", no_argument, NULL, 'P' },
{ "read-only", no_argument, NULL, 'r' },
@@ -701,6 +704,10 @@ int main(int argc, char **argv)
outarg = optarg;
list = 1;
break;
+ case OPT_OUTPUT_ALL:
+ for (ncolumns = 0; ncolumns < ARRAY_SIZE(infos); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 'P':
lo_flags |= LO_FLAGS_PARTSCAN;
break;
diff --git a/sys-utils/lscpu.1 b/sys-utils/lscpu.1
index b70f2e151..fa7a475ba 100644
--- a/sys-utils/lscpu.1
+++ b/sys-utils/lscpu.1
@@ -161,6 +161,10 @@ The CPU logical numbers are not affected by this option.
.TP
.BR \-V , " \-\-version"
Display version information and exit.
+.TP
+.B \-\-output\-all
+Output all available columns. This option must be combined with either
+.BR \-\-extended " or " \-\-parse .
.SH BUGS
The basic overview of CPU family, model, etc. is always based on the first
CPU only.
diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c
index fd6d63bbf..619a7df1d 100644
--- a/sys-utils/lscpu.c
+++ b/sys-utils/lscpu.c
@@ -1935,6 +1935,9 @@ int main(int argc, char *argv[])
int cpu_modifier_specified = 0;
size_t setsize;
+ enum {
+ OPT_OUTPUT_ALL = CHAR_MAX + 1,
+ };
static const struct option longopts[] = {
{ "all", no_argument, NULL, 'a' },
{ "online", no_argument, NULL, 'b' },
@@ -1947,6 +1950,7 @@ int main(int argc, char *argv[])
{ "physical", no_argument, NULL, 'y' },
{ "hex", no_argument, NULL, 'x' },
{ "version", no_argument, NULL, 'V' },
+ { "output-all", no_argument, NULL, OPT_OUTPUT_ALL },
{ NULL, 0, NULL, 0 }
};
@@ -2011,6 +2015,13 @@ int main(int argc, char *argv[])
case 'V':
printf(UTIL_LINUX_VERSION);
return EXIT_SUCCESS;
+ case OPT_OUTPUT_ALL:
+ {
+ size_t sz;
+ for (sz = 0; sz < ARRAY_SIZE(coldescs); sz++)
+ columns[sz] = 1;
+ break;
+ }
default:
errtryhelp(EXIT_FAILURE);
}
diff --git a/sys-utils/lsmem.1 b/sys-utils/lsmem.1
index f59c9937c..4476d3eaf 100644
--- a/sys-utils/lsmem.1
+++ b/sys-utils/lsmem.1
@@ -57,6 +57,9 @@ to get a list of all supported columns.
The default list of columns may be extended if \fIlist\fP is
specified in the format \fB+\fIlist\fP (e.g. \fBlsmem \-o +NODE\fP).
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.BR \-P , " \-\-pairs"
Produce output in the form of key="value" pairs.
All potentially unsafe characters are hex-escaped (\\x<code>).
diff --git a/sys-utils/lsmem.c b/sys-utils/lsmem.c
index 83a393046..0c7f05dec 100644
--- a/sys-utils/lsmem.c
+++ b/sys-utils/lsmem.c
@@ -498,6 +498,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -b, --bytes print SIZE in bytes rather than in human readable format\n"), out);
fputs(_(" -n, --noheadings don't print headings\n"), out);
fputs(_(" -o, --output <list> output columns\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" -r, --raw use raw output format\n"), out);
fputs(_(" -S, --split <list> split ranges by specified columns\n"), out);
fputs(_(" -s, --sysroot <dir> use the specified directory as system root\n"), out);
@@ -527,7 +528,8 @@ int main(int argc, char **argv)
size_t i;
enum {
- LSMEM_OPT_SUMARRY = CHAR_MAX + 1
+ LSMEM_OPT_SUMARRY = CHAR_MAX + 1,
+ OPT_OUTPUT_ALL
};
static const struct option longopts[] = {
@@ -537,6 +539,7 @@ int main(int argc, char **argv)
{"json", no_argument, NULL, 'J'},
{"noheadings", no_argument, NULL, 'n'},
{"output", required_argument, NULL, 'o'},
+ {"output-all", no_argument, NULL, OPT_OUTPUT_ALL},
{"pairs", no_argument, NULL, 'P'},
{"raw", no_argument, NULL, 'r'},
{"sysroot", required_argument, NULL, 's'},
@@ -581,6 +584,10 @@ int main(int argc, char **argv)
case 'o':
outarg = optarg;
break;
+ case OPT_OUTPUT_ALL:
+ for (ncolumns = 0; (size_t)ncolumns < ARRAY_SIZE(coldescs); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 'P':
lsmem->export = 1;
lsmem->want_summary = 0;
diff --git a/sys-utils/lsns.8 b/sys-utils/lsns.8
index 90009a780..aba372669 100644
--- a/sys-utils/lsns.8
+++ b/sys-utils/lsns.8
@@ -51,6 +51,9 @@ to get a list of all supported columns.
The default list of columns may be extended if \fIlist\fP is
specified in the format \fB+\fIlist\fP (e.g. \fBlsns \-o +PATH\fP).
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.BR \-p , " \-\-task " \fIpid\fP
Display only the namespaces held by the process with this \fIpid\fR.
.TP
diff --git a/sys-utils/lsns.c b/sys-utils/lsns.c
index 7264817a8..3050b505d 100644
--- a/sys-utils/lsns.c
+++ b/sys-utils/lsns.c
@@ -906,6 +906,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -l, --list use list format output\n"), out);
fputs(_(" -n, --noheadings don't print headings\n"), out);
fputs(_(" -o, --output <list> define which output columns to use\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" -p, --task <pid> print process namespaces\n"), out);
fputs(_(" -r, --raw use the raw output format\n"), out);
fputs(_(" -u, --notruncate don't truncate text in columns\n"), out);
@@ -931,11 +932,15 @@ int main(int argc, char *argv[])
int c;
int r = 0;
char *outarg = NULL;
+ enum {
+ OPT_OUTPUT_ALL = CHAR_MAX + 1
+ };
static const struct option long_opts[] = {
{ "json", no_argument, NULL, 'J' },
{ "task", required_argument, NULL, 'p' },
{ "help", no_argument, NULL, 'h' },
{ "output", required_argument, NULL, 'o' },
+ { "output-all", no_argument, NULL, OPT_OUTPUT_ALL },
{ "notruncate", no_argument, NULL, 'u' },
{ "version", no_argument, NULL, 'V' },
{ "noheadings", no_argument, NULL, 'n' },
@@ -980,6 +985,10 @@ int main(int argc, char *argv[])
case 'o':
outarg = optarg;
break;
+ case OPT_OUTPUT_ALL:
+ for (ncolumns = 0; ncolumns < ARRAY_SIZE(infos); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 'V':
printf(UTIL_LINUX_VERSION);
return EXIT_SUCCESS;
diff --git a/sys-utils/rfkill.8 b/sys-utils/rfkill.8
index 3c30c8ced..9eff913b8 100644
--- a/sys-utils/rfkill.8
+++ b/sys-utils/rfkill.8
@@ -34,6 +34,9 @@ Do not print a header line.
Specify which output columns to print. Use \-\-help to get a list of
available columns.
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
\fB\-r\fR, \fB\-\-raw\fR
Use the raw output format.
.TP
diff --git a/sys-utils/rfkill.c b/sys-utils/rfkill.c
index 57e1dddab..d87815a25 100644
--- a/sys-utils/rfkill.c
+++ b/sys-utils/rfkill.c
@@ -579,6 +579,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -J, --json use JSON output format\n"), stdout);
fputs(_(" -n, --noheadings don't print headings\n"), stdout);
fputs(_(" -o, --output <list> define which output columns to use\n"), stdout);
+ fputs(_(" --output-all output all columns\n"), stdout);
fputs(_(" -r, --raw use the raw output format\n"), stdout);
fputs(USAGE_SEPARATOR, stdout);
@@ -609,12 +610,16 @@ static void __attribute__((__noreturn__)) usage(void)
int main(int argc, char **argv)
{
struct control ctrl = { 0 };
- int c, act = ACT_LIST;
+ int c, act = ACT_LIST, list_all = 0;
char *outarg = NULL;
+ enum {
+ OPT_LIST_TYPES = CHAR_MAX + 1
+ };
static const struct option longopts[] = {
{ "json", no_argument, NULL, 'J' },
{ "noheadings", no_argument, NULL, 'n' },
{ "output", required_argument, NULL, 'o' },
+ { "output-all", no_argument, NULL, OPT_LIST_TYPES },
{ "raw", no_argument, NULL, 'r' },
{ "version", no_argument, NULL, 'V' },
{ "help", no_argument, NULL, 'h' },
@@ -644,6 +649,9 @@ int main(int argc, char **argv)
case 'o':
outarg = optarg;
break;
+ case OPT_LIST_TYPES:
+ list_all = 1;
+ break;
case 'r':
ctrl.raw = 1;
break;
@@ -690,6 +698,8 @@ int main(int argc, char **argv)
columns[ncolumns++] = COL_ID;
columns[ncolumns++] = COL_TYPE;
columns[ncolumns++] = COL_DEVICE;
+ if (list_all)
+ columns[ncolumns++] = COL_DESC;
columns[ncolumns++] = COL_SOFT;
columns[ncolumns++] = COL_HARD;
diff --git a/sys-utils/swapon.8 b/sys-utils/swapon.8
index 3c66c8188..b8fc8be71 100644
--- a/sys-utils/swapon.8
+++ b/sys-utils/swapon.8
@@ -160,6 +160,9 @@ Display a definable table of swap areas. See the
.B \-\-help
output for a list of available columns.
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.B \-\-noheadings
Do not print headings when displaying
.B \-\-show
diff --git a/sys-utils/swapon.c b/sys-utils/swapon.c
index 757601ae6..4ef2f1c9d 100644
--- a/sys-utils/swapon.c
+++ b/sys-utils/swapon.c
@@ -846,7 +846,8 @@ int main(int argc, char *argv[])
BYTES_OPTION = CHAR_MAX + 1,
NOHEADINGS_OPTION,
RAW_OPTION,
- SHOW_OPTION
+ SHOW_OPTION,
+ OPT_LIST_TYPES
};
static const struct option long_opts[] = {
@@ -861,6 +862,7 @@ int main(int argc, char *argv[])
{ "verbose", no_argument, NULL, 'v' },
{ "version", no_argument, NULL, 'V' },
{ "show", optional_argument, NULL, SHOW_OPTION },
+ { "output-all", no_argument, NULL, OPT_LIST_TYPES },
{ "noheadings", no_argument, NULL, NOHEADINGS_OPTION },
{ "raw", no_argument, NULL, RAW_OPTION },
{ "bytes", no_argument, NULL, BYTES_OPTION },
@@ -951,6 +953,10 @@ int main(int argc, char *argv[])
}
ctl.show = 1;
break;
+ case OPT_LIST_TYPES:
+ for (ctl.ncolumns = 0; (size_t)ctl.ncolumns < ARRAY_SIZE(infos); ctl.ncolumns++)
+ ctl.columns[ctl.ncolumns] = ctl.ncolumns;
+ break;
case NOHEADINGS_OPTION:
ctl.no_heading = 1;
break;
diff --git a/sys-utils/zramctl.8 b/sys-utils/zramctl.8
index 679a8a175..ccfb8901d 100644
--- a/sys-utils/zramctl.8
+++ b/sys-utils/zramctl.8
@@ -59,6 +59,9 @@ Define the status output columns to be used. If no output arrangement is
specified, then a default set is used.
Use \fB\-\-help\fP to get a list of all supported columns.
.TP
+.B \-\-output\-all
+Output all available columns.
+.TP
.B \-\-raw
Use the raw format for status output.
.TP
diff --git a/sys-utils/zramctl.c b/sys-utils/zramctl.c
index bedb0a042..642d88d41 100644
--- a/sys-utils/zramctl.c
+++ b/sys-utils/zramctl.c
@@ -543,6 +543,7 @@ static void __attribute__((__noreturn__)) usage(void)
fputs(_(" -f, --find find a free device\n"), out);
fputs(_(" -n, --noheadings don't print headings\n"), out);
fputs(_(" -o, --output <list> columns to use for status output\n"), out);
+ fputs(_(" --output-all output all columns\n"), out);
fputs(_(" --raw use raw status output format\n"), out);
fputs(_(" -r, --reset reset all specified devices\n"), out);
fputs(_(" -s, --size <size> device size\n"), out);
@@ -575,7 +576,10 @@ int main(int argc, char **argv)
int rc = 0, c, find = 0, act = A_NONE;
struct zram *zram = NULL;
- enum { OPT_RAW = CHAR_MAX + 1 };
+ enum {
+ OPT_RAW = CHAR_MAX + 1,
+ OPT_LIST_TYPES
+ };
static const struct option longopts[] = {
{ "algorithm", required_argument, NULL, 'a' },
@@ -583,6 +587,7 @@ int main(int argc, char **argv)
{ "find", no_argument, NULL, 'f' },
{ "help", no_argument, NULL, 'h' },
{ "output", required_argument, NULL, 'o' },
+ { "output-all",no_argument, NULL, OPT_LIST_TYPES },
{ "noheadings",no_argument, NULL, 'n' },
{ "reset", no_argument, NULL, 'r' },
{ "raw", no_argument, NULL, OPT_RAW },
@@ -625,6 +630,10 @@ int main(int argc, char **argv)
if (ncolumns < 0)
return EXIT_FAILURE;
break;
+ case OPT_LIST_TYPES:
+ for (ncolumns = 0; (size_t)ncolumns < ARRAY_SIZE(infos); ncolumns++)
+ columns[ncolumns] = ncolumns;
+ break;
case 's':
size = strtosize_or_err(optarg, _("failed to parse size"));
act = A_CREATE;