diff options
author | Jim Meyering <jim@meyering.net> | 2005-10-15 09:56:21 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2005-10-15 09:56:21 +0000 |
commit | 4ecdd8ce4cbe83f6b2e5b648dc4ba3b245cf45e3 (patch) | |
tree | a509e6cd211e6270c248375a4a938febe35b5e01 /src/ls.c | |
parent | 9624dcd0ee93aeee7af21abb5f3cb4bed8e3a3c8 (diff) | |
download | coreutils-4ecdd8ce4cbe83f6b2e5b648dc4ba3b245cf45e3.tar.xz |
(decode_switches): Warn about the deprecated --kilobytes option.
Diffstat (limited to 'src/ls.c')
-rw-r--r-- | src/ls.c | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -732,6 +732,10 @@ enum FULL_TIME_OPTION, HIDE_OPTION, INDICATOR_STYLE_OPTION, + + /* FIXME: --kilobytes is deprecated (but not -k); remove in late 2006 */ + KILOBYTES_LONG_OPTION, + QUOTING_STYLE_OPTION, SHOW_CONTROL_CHARS_OPTION, SI_OPTION, @@ -749,7 +753,7 @@ static struct option const long_options[] = {"full-time", no_argument, NULL, FULL_TIME_OPTION}, {"human-readable", no_argument, NULL, 'h'}, {"inode", no_argument, NULL, 'i'}, - {"kilobytes", no_argument, NULL, 'k'}, /* long form is obsolescent */ + {"kilobytes", no_argument, NULL, KILOBYTES_LONG_OPTION}, {"numeric-uid-gid", no_argument, NULL, 'n'}, {"no-group", no_argument, NULL, 'G'}, {"hide-control-chars", no_argument, NULL, 'q'}, @@ -1532,6 +1536,10 @@ decode_switches (int argc, char **argv) print_inode = true; break; + case KILOBYTES_LONG_OPTION: + error (0, 0, + _("the --kilobytes option is deprecated; use -k instead")); + /* fall through */ case 'k': human_output_opts = 0; file_output_block_size = output_block_size = 1024; |