From e452f2e8d6788458830bf2afe55d641e6adfa940 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Sat, 8 Feb 2014 19:34:02 +0200 Subject: [PATCH] cal,chfn,chsh,dmesg,eject,hexdump,look,newgrp,renice,runuser,su,write: Deprecate on Linux in favor of util-linux ones (Debian: #737672) --- bash_completion | 2 +- completions/Makefile.am | 25 ++++++++++++++----------- completions/{cal => _cal} | 3 +++ completions/_chfn | 8 ++++++++ completions/{chsh => _chsh} | 3 +++ completions/{dmesg => _dmesg} | 3 +++ completions/{eject => _eject} | 3 +++ completions/{hexdump => _hexdump} | 3 +++ completions/{look => _look} | 3 +++ completions/{newgrp => _newgrp} | 3 +++ completions/{renice => _renice} | 3 +++ completions/_runuser | 8 ++++++++ completions/{su => _su} | 3 +++ completions/_write | 8 ++++++++ 14 files changed, 66 insertions(+), 12 deletions(-) rename completions/{cal => _cal} (86%) create mode 100644 completions/_chfn rename completions/{chsh => _chsh} (82%) rename completions/{dmesg => _dmesg} (87%) rename completions/{eject => _eject} (85%) rename completions/{hexdump => _hexdump} (83%) rename completions/{look => _look} (73%) rename completions/{newgrp => _newgrp} (72%) rename completions/{renice => _renice} (84%) create mode 100644 completions/_runuser rename completions/{su => _su} (87%) create mode 100644 completions/_write diff --git a/bash_completion b/bash_completion index a63315aa..e7081afb 100644 --- a/bash_completion +++ b/bash_completion @@ -59,7 +59,7 @@ complete -d pushd # start of section containing compspecs that can be handled within bash # user commands see only users -complete -u write chfn groups slay w sux runuser +complete -u groups slay w sux # bg completes with stopped jobs complete -A stopped -P '"%' -S '"' bg diff --git a/completions/Makefile.am b/completions/Makefile.am index 44b07d78..7666ade4 100644 --- a/completions/Makefile.am +++ b/completions/Makefile.am @@ -31,7 +31,7 @@ bashcomp_DATA = 2to3 \ btdownloadheadless.py \ bts \ bzip2 \ - cal \ + _cal \ cancel \ cardctl \ ccache \ @@ -41,13 +41,14 @@ bashcomp_DATA = 2to3 \ change_pw \ check_db \ check_perms \ + _chfn \ chgrp \ chkconfig \ chown \ chpasswd \ chronyc \ chrpath \ - chsh \ + _chsh \ cksfv \ cleanarch \ clisp \ @@ -69,7 +70,7 @@ bashcomp_DATA = 2to3 \ desktop-file-validate \ dhclient \ dict \ - dmesg \ + _dmesg \ dnsspoof \ dot \ dpkg \ @@ -80,7 +81,7 @@ bashcomp_DATA = 2to3 \ dumpe2fs \ e2freefrag \ e2label \ - eject \ + _eject \ eog \ ether-wake \ evince \ @@ -125,7 +126,7 @@ bashcomp_DATA = 2to3 \ gzip \ hcitool \ hddtemp \ - hexdump \ + _hexdump \ hid2hci \ hping2 \ htop \ @@ -183,7 +184,7 @@ bashcomp_DATA = 2to3 \ list_lists \ list_members \ list_owners \ - look \ + _look \ lpq \ lpr \ lrzip \ @@ -233,7 +234,7 @@ bashcomp_DATA = 2to3 \ nc \ ncftp \ nethogs \ - newgrp \ + _newgrp \ newlist \ newusers \ ngrep \ @@ -293,7 +294,7 @@ bashcomp_DATA = 2to3 \ rdesktop \ remove_members \ removepkg \ - renice \ + _renice \ _repomanage \ reportbug \ reptyr \ @@ -310,6 +311,7 @@ bashcomp_DATA = 2to3 \ rrdtool \ rsync \ _rtcwake \ + _runuser \ sbcl \ sbopkg \ screen \ @@ -332,7 +334,7 @@ bashcomp_DATA = 2to3 \ sshow \ strace \ strings \ - su \ + _su \ sudo \ svcadm \ svk \ @@ -376,6 +378,7 @@ bashcomp_DATA = 2to3 \ withlist \ wodim \ wol \ + _write \ wsimport \ wtf \ wvdial \ @@ -640,7 +643,7 @@ symlinks: $(targetdir) $(DATA) done for file in ncal ; do \ rm -f $(targetdir)/$$file && \ - $(LN_S) cal $(targetdir)/$$file ; \ + $(LN_S) _cal $(targetdir)/$$file ; \ done for file in pccardctl ; do \ rm -f $(targetdir)/$$file && \ @@ -706,7 +709,7 @@ symlinks: $(targetdir) $(DATA) done for file in hd ; do \ rm -f $(targetdir)/$$file && \ - $(LN_S) hexdump $(targetdir)/$$file ; \ + $(LN_S) _hexdump $(targetdir)/$$file ; \ done for file in hping hping3 ; do \ rm -f $(targetdir)/$$file && \ diff --git a/completions/cal b/completions/_cal similarity index 86% rename from completions/cal rename to completions/_cal index 880b0b35..0a5c8542 100644 --- a/completions/cal +++ b/completions/_cal @@ -1,5 +1,8 @@ # cal(1) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _cal() { local cur prev words cword diff --git a/completions/_chfn b/completions/_chfn new file mode 100644 index 00000000..23f24c3b --- /dev/null +++ b/completions/_chfn @@ -0,0 +1,8 @@ +# chfn(1) completion -*- shell-script -*- + +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + +complete -u chfn + +# ex: ts=4 sw=4 et filetype=sh diff --git a/completions/chsh b/completions/_chsh similarity index 82% rename from completions/chsh rename to completions/_chsh index f65291a1..786bcfda 100644 --- a/completions/chsh +++ b/completions/_chsh @@ -1,5 +1,8 @@ # chsh(1) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _chsh() { local cur prev words cword diff --git a/completions/dmesg b/completions/_dmesg similarity index 87% rename from completions/dmesg rename to completions/_dmesg index 3d9bc662..4ca6d97d 100644 --- a/completions/dmesg +++ b/completions/_dmesg @@ -1,5 +1,8 @@ # dmesg(1) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _dmesg() { [[ $OSTYPE == *solaris* ]] && return # no args there diff --git a/completions/eject b/completions/_eject similarity index 85% rename from completions/eject rename to completions/_eject index d6b1f6d9..7f025ac5 100644 --- a/completions/eject +++ b/completions/_eject @@ -1,5 +1,8 @@ # bash completion for eject(1) -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _eject() { local cur prev words cword diff --git a/completions/hexdump b/completions/_hexdump similarity index 83% rename from completions/hexdump rename to completions/_hexdump index c566f9d6..632ef824 100644 --- a/completions/hexdump +++ b/completions/_hexdump @@ -1,5 +1,8 @@ # hexdump(1) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _hexdump() { local cur prev words cword diff --git a/completions/look b/completions/_look similarity index 73% rename from completions/look rename to completions/_look index df914452..a38c1cdc 100644 --- a/completions/look +++ b/completions/_look @@ -1,5 +1,8 @@ # look(1) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _look() { local cur prev words cword diff --git a/completions/newgrp b/completions/_newgrp similarity index 72% rename from completions/newgrp rename to completions/_newgrp index ddcd79e8..acf85441 100644 --- a/completions/newgrp +++ b/completions/_newgrp @@ -1,5 +1,8 @@ # newgrp(1) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _newgrp() { local cur prev words cword diff --git a/completions/renice b/completions/_renice similarity index 84% rename from completions/renice rename to completions/_renice index 60968eef..68743fdf 100644 --- a/completions/renice +++ b/completions/_renice @@ -1,5 +1,8 @@ # renice(8) completion -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + _renice() { local cur prev words cword diff --git a/completions/_runuser b/completions/_runuser new file mode 100644 index 00000000..95c53fb7 --- /dev/null +++ b/completions/_runuser @@ -0,0 +1,8 @@ +# runuser(1) completion -*- shell-script -*- + +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + +complete -u runuser + +# ex: ts=4 sw=4 et filetype=sh diff --git a/completions/su b/completions/_su similarity index 87% rename from completions/su rename to completions/_su index fccca47b..fb01deea 100644 --- a/completions/su +++ b/completions/_su @@ -1,5 +1,8 @@ # bash completion for su(1) -*- shell-script -*- +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + if [[ $OSTYPE != *linux* ]]; then complete -u su # default completion return diff --git a/completions/_write b/completions/_write new file mode 100644 index 00000000..86ef4488 --- /dev/null +++ b/completions/_write @@ -0,0 +1,8 @@ +# write(1) completion -*- shell-script -*- + +# Use of this file is deprecated on Linux. Upstream completion is +# available in util-linux >= 2.23, use that instead. + +complete -u write + +# ex: ts=4 sw=4 et filetype=sh