- add some parameters to apt-get completion
(patch by Rafael Sepúlveda <drs@gnulinux.org.mx> - white-space clean-up
This commit is contained in:
parent
244278af53
commit
d1745551a9
@ -1,6 +1,6 @@
|
|||||||
# bash_completion - some programmable completion functions for bash 2.05b
|
# bash_completion - some programmable completion functions for bash 2.05b
|
||||||
#
|
#
|
||||||
# $Id: bash_completion,v 1.411 2002/09/19 06:21:32 ianmacd Exp $
|
# $Id: bash_completion,v 1.412 2002/09/28 18:12:24 ianmacd Exp $
|
||||||
#
|
#
|
||||||
# Copyright (C) Ian Macdonald <ian@caliban.org>
|
# Copyright (C) Ian Macdonald <ian@caliban.org>
|
||||||
#
|
#
|
||||||
@ -241,7 +241,7 @@ _alias()
|
|||||||
local cur
|
local cur
|
||||||
|
|
||||||
COMPREPLY=()
|
COMPREPLY=()
|
||||||
cur=${COMP_WORDS[$COMP_CWORD]};
|
cur=${COMP_WORDS[$COMP_CWORD]}
|
||||||
|
|
||||||
case "$COMP_LINE" in
|
case "$COMP_LINE" in
|
||||||
*[^=])
|
*[^=])
|
||||||
@ -262,7 +262,7 @@ _export()
|
|||||||
local cur
|
local cur
|
||||||
|
|
||||||
COMPREPLY=()
|
COMPREPLY=()
|
||||||
cur=${COMP_WORDS[$COMP_CWORD]};
|
cur=${COMP_WORDS[$COMP_CWORD]}
|
||||||
|
|
||||||
case "$COMP_LINE" in
|
case "$COMP_LINE" in
|
||||||
*=\$*)
|
*=\$*)
|
||||||
@ -1457,12 +1457,16 @@ _apt_get()
|
|||||||
|
|
||||||
if [[ "$prev" == -*c ]] || [ "$prev" = --config-file ]; then
|
if [[ "$prev" == -*c ]] || [ "$prev" = --config-file ]; then
|
||||||
_filedir
|
_filedir
|
||||||
|
|
||||||
|
elif [[ "$prev" == -*h ]] || [ "$prev" = --help ]; then
|
||||||
|
return 0
|
||||||
|
|
||||||
else
|
else
|
||||||
COMPREPLY=( $( compgen -W 'update upgrade dselect-upgrade \
|
COMPREPLY=( $( compgen -W 'update upgrade dselect-upgrade \
|
||||||
dist-upgrade install remove source \
|
dist-upgrade install remove source \
|
||||||
build-dep check \
|
build-dep check clean autoclean \
|
||||||
clean autoclean -d -f -h -v -m -q -s -y -u \
|
-d -f -h -v -m -q -s -y -u -b -c -o -t \
|
||||||
-b -c -o --download-only --fix-broken --help \
|
--download-only --fix-broken --help \
|
||||||
--version --ignore-missing --fix-missing \
|
--version --ignore-missing --fix-missing \
|
||||||
--no-download --quiet --simulate \
|
--no-download --quiet --simulate \
|
||||||
--just-print --dry-run --recon --no-act \
|
--just-print --dry-run --recon --no-act \
|
||||||
@ -1470,8 +1474,10 @@ _apt_get()
|
|||||||
--compile --build --ignore-hold \
|
--compile --build --ignore-hold \
|
||||||
--no-upgrade --force-yes --print-uris \
|
--no-upgrade --force-yes --print-uris \
|
||||||
--purge --reinstall --list-cleanup \
|
--purge --reinstall --list-cleanup \
|
||||||
|
--target-release --default-release \
|
||||||
--trivial-only --no-remove --diff-only \
|
--trivial-only --no-remove --diff-only \
|
||||||
--tar-only --config-file --option' -- $cur ) )
|
--only-source --diff-only --tar-only \
|
||||||
|
--config-file --option' -- $cur ) )
|
||||||
fi
|
fi
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
@ -1526,7 +1532,7 @@ _apt_cache()
|
|||||||
[ "$have" ] && complete -F _apt-cache $filenames apt-cache
|
[ "$have" ] && complete -F _apt-cache $filenames apt-cache
|
||||||
complete -F _apt_cache $filenames apt-cache
|
complete -F _apt_cache $filenames apt-cache
|
||||||
|
|
||||||
# Debian Linux aptitude(1) completion
|
# Debian aptitude(1) completion
|
||||||
#
|
#
|
||||||
have aptitude && {
|
have aptitude && {
|
||||||
_comp-dpkg-hold-packages()
|
_comp-dpkg-hold-packages()
|
||||||
@ -1632,14 +1638,14 @@ _apt_build()
|
|||||||
|
|
||||||
if [[ "$prev" = --patch ]]; then
|
if [[ "$prev" = --patch ]]; then
|
||||||
_filedir
|
_filedir
|
||||||
return 0;
|
return 0
|
||||||
|
|
||||||
elif [[ "$prev" = --patch-strip ]]; then
|
elif [[ "$prev" = --patch-strip ]]; then
|
||||||
return 0;
|
return 0
|
||||||
|
|
||||||
#a little hand in this option will be helpful :)
|
#a little hand in this option will be helpful :)
|
||||||
elif [[ "$prev" = --build-command ]]; then
|
elif [[ "$prev" = --build-command ]]; then
|
||||||
return 0;
|
return 0
|
||||||
|
|
||||||
else
|
else
|
||||||
COMPREPLY=( $( compgen -W "update upgrade install remove \
|
COMPREPLY=( $( compgen -W "update upgrade install remove \
|
||||||
@ -3416,7 +3422,7 @@ _reportbug()
|
|||||||
-S|--severity)
|
-S|--severity)
|
||||||
COMPREPLY=( $( compgen -W "grave serious important normal \
|
COMPREPLY=( $( compgen -W "grave serious important normal \
|
||||||
minor wishlist" -- $cur ) )
|
minor wishlist" -- $cur ) )
|
||||||
return 0;
|
return 0
|
||||||
;;
|
;;
|
||||||
-u|--ui|--interface)
|
-u|--ui|--interface)
|
||||||
COMPREPLY=( $( compgen -W "newt text gnome" -- $cur ) )
|
COMPREPLY=( $( compgen -W "newt text gnome" -- $cur ) )
|
||||||
@ -3424,12 +3430,12 @@ _reportbug()
|
|||||||
;;
|
;;
|
||||||
-t|--type)
|
-t|--type)
|
||||||
COMPREPLY=( $( compgen -W "gnats debbugs" -- $cur ) )
|
COMPREPLY=( $( compgen -W "gnats debbugs" -- $cur ) )
|
||||||
return 0;
|
return 0
|
||||||
;;
|
;;
|
||||||
-T|--tags)
|
-T|--tags)
|
||||||
COMPREPLY=( $( compgen -W "none patch security upstream sid \
|
COMPREPLY=( $( compgen -W "none patch security upstream sid \
|
||||||
woody potato sarge fixed" -- $cur ) )
|
woody potato sarge fixed" -- $cur ) )
|
||||||
return 0;
|
return 0
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
;;
|
;;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user