aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Harder <radhermit@gentoo.org>2014-12-19 18:12:28 -0800
committerTim Harder <radhermit@gentoo.org>2014-12-19 18:13:45 -0800
commit210cbb7c3cf71e2d7da85c4e167ce2bdd265da3a (patch)
tree49e8da77e93c4aefe686fdab3726ccd92e717075
parentmove duplicated repos functionality to _gentoo_repos (diff)
downloadzsh-completion-210cbb7c3cf71e2d7da85c4e167ce2bdd265da3a.tar.gz
zsh-completion-210cbb7c3cf71e2d7da85c4e167ce2bdd265da3a.tar.bz2
zsh-completion-210cbb7c3cf71e2d7da85c4e167ce2bdd265da3a.zip
_portage: add optional arguments for quickpkg
-rw-r--r--src/_portage21
1 files changed, 16 insertions, 5 deletions
diff --git a/src/_portage b/src/_portage
index e9639d8..efa3c0e 100644
--- a/src/_portage
+++ b/src/_portage
@@ -41,16 +41,27 @@ _ebuild () {
}
-# Stuff for quickpkg
-
_quickpkg () {
+ local optional_args
+
+ optional_args=(
+ "(: -)"{-h,--help}'[show this help message and exit]'
+ "--umask[umask used during package creation (default is 0077)]:umask (octal)"
+ "--ignore-default-opts[do not use the QUICKPKG_DEFAULT_OPTS environment variable]"
+ "--include-config[include all files protected by CONFIG_PROTECT (as a security precaution, default is 'n')]:y or n:((y n))"
+ "--include-unmodified-config[include files protected by CONFIG_PROTECT that have not been modified since installation (as a security precaution, default is 'n')]:y or n:((y n))"
+ )
+
if compset -P '(\\|)(>=|<=|<|>|=)'; then
- _arguments -s \
- '*:installed package:_gentoo_packages installed_versions'
+ _arguments -s \
+ "$optional_args[@]" \
+ '*:installed package:_gentoo_packages installed_versions'
elif compset -P '(\\|)[/]'; then
_path_files -W / -/
else
- _arguments '*:installed package:_gentoo_packages installed'
+ _arguments \
+ "$optional_args[@]" \
+ '*:installed package:_gentoo_packages installed'
fi
}