* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2013-02-07 20:15 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2013-02-07 20:15 UTC (permalink / raw
To: gentoo-commits
commit: d9a4597e38afe9cafd90683e75cc87a837e3cbab
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 6 23:48:56 2013 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Wed Feb 6 23:48:56 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=d9a4597e
check for /etc/portage/make.conf and the new make.globals location
---
_gcc-config | 2 +-
_gentoo_packages | 38 ++++++++++++++++++++++++++------------
_portage_utils | 7 +++++--
3 files changed, 32 insertions(+), 15 deletions(-)
diff --git a/_gcc-config b/_gcc-config
index d6e5bb8..3b0fcf3 100644
--- a/_gcc-config
+++ b/_gcc-config
@@ -5,7 +5,7 @@ local arguments
arguments=(
'(- :)'{--use-old,-O}'[use the old profile if one was selected]'
- '(- :)'{--use-portage-chost,-P}'[only set profile if its CHOST matches /etc/make.conf]:profiles:_gcc_profile'
+ '(- :)'{--use-portage-chost,-P}'[only set profile if its CHOST matches /etc/{portage/}make.conf]:profiles:_gcc_profile'
'(- :)'{--get-current-profile,-c}'[print current used gcc profile]'
'(- :)'{--list-profiles,-l}'[print a list of available profiles]'
'(- :)'{--print-environ,-E}'[print environment of the given/current profile]:profiles:_gcc_profile'
diff --git a/_gentoo_packages b/_gentoo_packages
index f1a0278..767d592 100644
--- a/_gentoo_packages
+++ b/_gentoo_packages
@@ -9,10 +9,12 @@
_gentoo_packages_update_useflag(){
local flags PORTDIR
var=PORTDIR
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.globals ]] &&
- local $var="`. /etc/make.globals 2>/dev/null; echo ${(P)var}`"
+ [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
+ local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
flags=( ${${(M)${(f)"$(<$PORTDIR/profiles/use.desc)"}:#* - *}%% - *}
${${${(M)${(f)"$(<$PORTDIR/profiles/use.local.desc)"}#* - *}%% - *}#*:} )
@@ -22,6 +24,8 @@ _gentoo_packages_update_useflag(){
_gentoo_packages_update_active_useflag(){
local flags USE
var=USE
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
flags=(${${${=USE}%-*}%\\*})
@@ -30,10 +34,12 @@ _gentoo_packages_update_active_useflag(){
_gentoo_packages_update_category(){
local var trees category
for var in PORTDIR PORTDIR_OVERLAY ; do
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.globals ]] &&
- local $var="`. /etc/make.globals 2>/dev/null; echo ${(P)var}`"
+ [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
+ local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
done
trees=($PORTDIR $=PORTDIR_OVERLAY)
category=( $trees/*-*(/:t) )
@@ -67,10 +73,12 @@ _gentoo_packages_update_available_pkgnames_only(){
local var trees packages
for var in PORTDIR PORTDIR_OVERLAY ; do
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.globals ]] &&
- local $var="`. /etc/make.globals 2>/dev/null; echo ${(P)var}`"
+ [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
+ local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
done
trees=( $PORTDIR $=PORTDIR_OVERLAY)
@@ -82,10 +90,12 @@ _gentoo_packages_update_available(){
local var trees category packages pkg expl
for var in PORTDIR PORTDIR_OVERLAY ; do
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.globals ]] &&
- local $var="`. /etc/make.globals 2>/dev/null; echo ${(P)var}`"
+ [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
+ local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
done
trees=( $PORTDIR $=PORTDIR_OVERLAY)
category=( $trees/*-*(/:t) )
@@ -110,10 +120,12 @@ _gentoo_packages_update_available_versions(){
local var overlay_ebuilds portage_ebuilds expl trees category
for var in PORTDIR PORTDIR_OVERLAY ; do
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.globals ]] &&
- local $var="`. /etc/make.globals 2>/dev/null; echo ${(P)var}`"
+ [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
+ local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
done
trees=($PORTDIR $=PORTDIR_OVERLAY)
category=( $trees/*-*(/:t) )
@@ -130,10 +142,12 @@ _gentoo_packages_update_available_versions(){
#Function to show tbz2 files available
_gentoo_packages_update_binary() {
+ [[ -z $PKGDIR && -r /etc/portage/make.conf ]] &&
+ local PKGDIR="`. /etc/portage/make.conf 2>/dev/null; echo $PKGDIR`"
[[ -z $PKGDIR && -r /etc/make.conf ]] &&
local PKGDIR="`. /etc/make.conf 2>/dev/null; echo $PKGDIR`"
- [[ -z $PKGDIR && -r /etc/make.globals ]] &&
- local PKGDIR="`. /etc/make.globals 2>/dev/null; echo $PKGDIR`"
+ [[ -z $PKGDIR && -r /usr/share/portage/config/make.globals ]] &&
+ local PKGDIR="`. /usr/share/portage/config/make.globals 2>/dev/null; echo $PKGDIR`"
# this doesn't take care of ${PORTAGE_BINHOST}. If Gentoo official
# binary mirror will be available we should rewrite it accordingly.
diff --git a/_portage_utils b/_portage_utils
index d18bd12..fc3b776 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -4,10 +4,13 @@
#
local common_args PORTDIR
var=PORTDIR
+[[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
-[[ -z ${(P)var} && -r /etc/make.globals ]] &&
-local $var="`. /etc/make.globals 2>/dev/null; echo ${(P)var}`"
+[[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
+local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
+
common_args=(
{'(--verbose)-v','(-v)--verbose'}'[Make a lot of noise]' \
{'(--quiet)-q','(-q)--quiet'}'[Tighter output; suppress warnings]' \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2013-02-07 20:15 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2013-02-07 20:15 UTC (permalink / raw
To: gentoo-commits
commit: aab7e2303cba8ea74092f812137c2f9ad584351d
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 6 23:22:47 2013 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Wed Feb 6 23:22:47 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=aab7e230
eix optionally installs its own zsh completion files now
---
_eix | 193 ------------------------------------------------------------------
1 files changed, 0 insertions(+), 193 deletions(-)
diff --git a/_eix b/_eix
deleted file mode 100644
index 07726ef..0000000
--- a/_eix
+++ /dev/null
@@ -1,193 +0,0 @@
-#compdef eix
-
-# options from eix --help
-# eix 0.10.3 (gcc-4.2.2, x86_64-pc-linux-gnu)
-#
-
-
-# category of options
-local global_exclusives_opts \
- global_special \
- global_output \
- local_misc \
- local_search_field \
- local_type_of_pattern
-
-global_exclusives_opts=(
- {'(--help)-h','(-h)--help'}'[show help and exit]'
- {'(--version)-V','(-V)--version'}'[show version and exit]'
- '--dump[dump variables to stdout]'
- '--dump-defaults[dump default values of variables]'
- '--print[print the expanded value of a variable]'
- '--print-all-useflags[print all IUSE words used in some version]'
- '--print-all-keywords[print all KEYWORDS used in some version]'
- '--print-all-slots[print all SLOT strings used in some version]'
- '--print-all-provides[print all PROVIDE strings used in some package]'
- '--print-all-licenses[print all LICENSE strings used in some package]'
- '--print-world-sets[print the world sets]'
- '--print-overlay-path[print the path of specified overlay]'
- '--print-overlay-label[print label of specified overlay]'
-)
-
-global_special=(
- {'(--test-non-matching)-t','(-t)--test-non-matching'}'[print non-matching entries of /etc/portage/package.* and non-matching names of installed packages]'
- {'(--quick)-Q','(-Q)--quick'}"[(toggle) don't read unguessable slots of installed packages]"
- '--care[always read slots of installed packages]'
- '--cache-file[use another cache-file instead of /var/cache/eix]'
-)
-
-global_output=(
- {'(--quiet)-q','(-q)--quiet'}'[(toggle) (no) output]'
- {'(--nocolor)-n','(-n)--nocolor'}'[do not use ANSI color codes]'
- {'(--force-color)-F','(-F)--force-color'}'[force colorful output]'
- {'(--pure-packages)-\\*','(-\\*)--pure-packages'}'[Omit printing of overlay names and package number]'
- '--only-names[print with format <category>/<name>]'
- {'(--compact)-c','(-c)--compact'}'[(toggle) compact search results]'
- {'(--verbose)-v','(-v)--verbose'}'[(toggle) verbose search results]'
- {'(--versionsort)-x','(-x)--versionsort'}'[(toggle) sort output by slots/versions]'
- {'(--versionlines)-l','(-l)--versionlines'}'[(toggle) print available versions line-by-line]' \
- '--format[format string for normal output]'
- '--format-compact[format string for compact output]'
- '--format-verbose[format string for verbose outp]'
-)
-
-local_misc=(
- {'(--installed)-I','(-I)--installed'}'[Next expression only matches installed packages]'
- {'(--multi-installed)-i','(-i)--multi-installed'}'[Match packages installed in several versions]'
- {'(--dup-packages)-d','(-d)--dup-packages'}'[Match duplicated packages]'
- {'(--dup-versions)-D','(-D)--dup-versions'}'[Match packages with duplicated versions]'
- {'(--slotted)-1','(-1)--slotted'}'[Match packages with a nontrivial slot]'
- {'(--slots)-2','(-2)--slots'}'[Match packages with two different slots]'
- {'(--upgrade)-u','(-u)--upgrade'}'[Match packages without best slotted version]'
- '--stable[Match packages with a stable version]'
- '--testing[Match packages with a testing or stable version]'
- '--non-masked[Match packages with a non-masked version]'
- '--system[Match system packages]'
- '--installed-unstable[Match packages with a non-stable installed version]'
- '--installed-testing[Match packages with a testing installed version]'
- '--installed-masked[Match packages with a masked installed version]'
- '--world[Match world packages]'
- '--world-all[Match packages of world or of a world set]'
- '--world-set[Match packages of a world set]'
- {'(--overlay)-O','(-O)--overlay'}'[Match packages from overlays]'
- '--in-overlay[OVERLAY Match packages from OVERLAY]'
- '--only-in-overlay[OVERLAY Match packages only in OVERLAY]'
- {'(--installed-overlay)-J','(-J)--installed-overlay'}'[Match packages installed from overlays]'
- '--installed-from-overlay[OVERLAY Packages installed from OVERLAY]'
- '--installed-in-some-overlay[Packages with an installed version provided by some overlay]'
- '--installed-in-overlay[OVERLAY Packages with an installed version provided from OVERLAY]'
- '--restrict-fetch[Match packages with a fetch restriction]'
- '--restrict-mirror[Match packages with a mirror restriction]'
- '--restrict-primaryuri[Match packages with RESTRICT=primaryuri]'
- '--restrict-binchecks[Match packages with RESTRICT=binchecks]'
- '--restrict-strip[Match packages with RESTRICT=strip]'
- '--restrict-test[Match packages with RESTRICT=test]'
- '--restrict-userpriv[Match packages with RESTRICT=userpriv]'
- '--restrict-installsources[Match packages with RESTRICT=installsources]'
- '--restrict-bindist[Match packages with RESTRICT=bindist]'
- '--properties-interactive[Match packages with PROPERTIES=interactive]'
- '--properties-live[Match packages with PROPERTIES=live]'
- '--properties-virtual[ Match packages with PROPERTIES=virtual]'
- '--properties-set[Match packages with PROPERTIES=set]'
- {'(--test-obsolete)-T','(-T)--test-obsolete'}'[Match packages with obsolete entries in /etc/portage/package.*]'
- {'(--not)-!','(-!)--not'}'[(toggle) Invert the expression]'
- {'(--pipe)-\\|','(-\\|)--pipe'}'[Use input from pipe of emerge -pv]'
-)
-
-local_search_field=(
- {'(--description)-S','(-S)--description'}'[description]'
- {'(--category-name)-A','(-A)--category-name'}'["category/name"]'
- {'(--category)-C','(-C)--category'}'[category]'
- {'(--name)-s','(-s)--name'}'[name (default)]'
- {'(--homepage)-H','(-H)--homepage'}'[homepage]'
- {'(--license)-L','(-L)--license'}'[license]'
- {'(--provide)-P','(-P)--provide'}'[provides]'
- {'(--use)-U','(-U)--use'}'[useflag (of the ebuild)]'
- '--installed-with-use[enabled useflag (of installed package)]'
- '--installed-without-use[disabled useflag (of installed package)]'
-)
-
-local_type_of_pattern=(
- {'(--regex)-r','(-r)--regex'}'[Pattern is a regexp (default)]'
- {'(--exact)-e','(-e)--exact'}'[Pattern is the exact string]'
- {'(--substring)-z','(-z)--substring'}'[Pattern is a substring]'
- {'(--begin)-b','(-b)--begin'}'[Pattern is the beginning of the string]'
- '--end[Pattern is the end of the string]'
- {'(--pattern)-p','(-p)--pattern'}'[Pattern is a wildcards-pattern]'
- {'(--fuzzy)-f','(-f)--fuzzy'}'[Use fuzzy-search with a max. levenshtein-distance m (default: 2)]'
-)
-
-
-local prev="$words[CURRENT-1]" # previous word
-local _gentoo_packages_scope # used to restrict the package scope (installed,category,useflag...)
-
-# global exclusiv opts, no more completion.
-if (( $words[(I)(-[[:alnum:]]#(h|V)[[:alnum:]]#|--(help|version|dump|dump-defaults))] )); then
- return 0
-# already have a --print ARG option. no more completion.
-elif (( $words[(I)(--print)] )) && [[ "$prev" != '--print' ]]; then
- return 0
-else
- case "$prev" in
-# eix variables for --print
- '--print' )
- local vars
- vars=(${${(M)${(f)"$(eix --dump)"}##[A-Z]*}%%\=*})
- _values 'variables' $vars
- return 0
- ;;
-
-# files for --cache-file
- '--cache-file' )
- _arguments -s '*:filename:_files'
- return 0
- ;;
-
-# overlays for --only-in-overlay|--in-overlay|--installed-from-overlay|--installed-in-overlay
- --((only-|)in|installed-(from|in))-overlay )
- for f in /etc/make.conf /etc/make.globals; do
- [[ -z "$PORTDIR_OVERLAY" && -r "$f" ]] &&
- local PORTDIR_OVERLAY="`. "$f" 2>/dev/null; echo ${PORTDIR_OVERLAY}`"
- done
-
- _values 'overlays' $=PORTDIR_OVERLAY
- return 0
- ;;
-
-# useflags for -U|--use|--installed-with-use|--installed-without-use
- (-[[:alnum:]]#U|--(use|installed-with(out|)-use)) )
- _gentoo_packages_scope='*:package:_gentoo_packages useflag'
- ;;
-
-# category for -C|--category
- -([[:alnum:]]#C|-category) )
- _gentoo_packages_scope='*:package:_gentoo_packages category'
- ;;
-
- * )
- #if (( $words[(I)(-[[:alnum:]]#2[[:alnum:]]#|--slots)] )); then
- # local pkgs
- # pkgs=(${${(f)"$(eix -2 --only-names)"}##*/})
- # _values 'packages' $pkgs && return 0
-
- # installed packages for -i|--installed|-I|--multi-installed|-T|--test-obsolete
- if (( $words[(I)(-[[:alnum:]]#(i|I|T)[[:alnum:]]#|--(((multi-|)installed)|test-obsolete))] )); then
- _gentoo_packages_scope='*:package:_gentoo_packages installed'
- # only packages names (no category) for -s|--name
- elif (( $words[(I)(-[[:alnum:]]#s[[:alnum:]]#|--name)] )); then
- _gentoo_packages_scope='*:package:_gentoo_packages available_pkgnames_only'
- else # default
- _gentoo_packages_scope='*:package:_gentoo_packages available'
- fi
- ;;
- esac
-fi
-
-_arguments -s $global_exclusives_opts \
- $global_special \
- $global_output \
- $local_misc \
- $local_search_field \
- $local_type_of_pattern \
- $_gentoo_packages_scope &&
- return 0
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-01-24 1:05 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-01-24 1:05 UTC (permalink / raw
To: gentoo-commits
commit: 1f974c2e3fd1a9124134cc28f6e2d93b214c3c4d
Author: Vikraman Choudhury <vikraman <AT> gentoo <DOT> org>
AuthorDate: Thu Jan 23 22:47:16 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Jan 24 01:02:15 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=1f974c2e
Use --{color,colour} options
--no-{color,colour} is deprecated and removed in eselect 1.4.
---
_eselect | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/_eselect b/_eselect
index 130016a..5b15d50 100644
--- a/_eselect
+++ b/_eselect
@@ -15,7 +15,7 @@ _eselect_env () {
_eselect_binutils () {
local binutilslist
if (( $words[(I)(set)] )); then
- binutilslist=(${${${(M)${(f)"$(eselect --no-color binutils list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ binutilslist=(${${${(M)${(f)"$(eselect --color=no binutils list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available binutils version" $binutilslist[@] && return 0
fi
_values "binutils options" \
@@ -30,7 +30,7 @@ _eselect_binutils () {
_eselect_kernel () {
local kernellist
if (( $words[(I)(set)] )); then
- kernellist=(${${${(M)${(f)"$(eselect --no-color kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ kernellist=(${${${(M)${(f)"$(eselect --color=no kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available kernel version" $kernellist[@] && return 0
fi
_values "kenrel options" \
@@ -44,7 +44,7 @@ _eselect_kernel () {
_eselect_ctags () {
local ctagslist
if (( $words[(I)(set)] )); then
- ctagslist=(${${${(M)${(f)"$(eselect --no-color ctags list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ ctagslist=(${${${(M)${(f)"$(eselect --color=no ctags list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available ctags version" $ctagslist[@] && return 0
fi
_values "ctags options" \
@@ -59,7 +59,7 @@ _eselect_ctags () {
_eselect_profile () {
local profilelist
if (( $words[(I)(set)] )); then
- profilelist=(${${${(M)${(f)"$(eselect --no-color profile list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ profilelist=(${${${(M)${(f)"$(eselect --color=no profile list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values -w "available profiles" $profilelist[@] \
"--force[Forcibly set the symlink]" && return 0
fi
@@ -74,10 +74,10 @@ _eselect_profile () {
_eselect_fontconfig () {
local fclistenabled fclistdisabled
if (( $words[(I)(enable)] )); then
- fclistdisabled=(${${${${(M)${(f)"$(eselect --no-color fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
+ fclistdisabled=(${${${${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
_values -w ".conf to enable" $fclistdisabled[@] && return 0
elif (( $words[(I)(disable)] )); then
- fclistenabled=(${${${(M)${(M)${(f)"$(eselect --no-color fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
+ fclistenabled=(${${${(M)${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
_values -w ".conf to disable" $fclistenabled[@] && return 0
fi
_values "fontconfig options" \
@@ -91,7 +91,7 @@ _eselect_fontconfig () {
_eselect_opengl () {
local opengllist
if (( $words[(I)(set)] )); then
- opengllist=(${${${(M)${(f)"$(eselect --no-color opengl list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ opengllist=(${${${(M)${(f)"$(eselect --color=no opengl list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values -w "opengl implementations and options" $opengllist[@] \
"--use-old[If an implementationis already set, use that one instead]" \
"--prefix[Set the source prefix]:path:_files -/" \
@@ -109,7 +109,7 @@ _eselect_opengl () {
_eselect_vi () {
local vilist
if (( $words[(I)(set)] )); then
- vilist=(${${${(M)${(f)"$(eselect --no-color vi list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ vilist=(${${${(M)${(f)"$(eselect --color=no vi list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values -w "vi implementation" $vilist[@] && return 0
elif (( $words[(I)(update)] )); then
_values -w "option" "--if-unset[Do not override existing implementation]" && return 0
@@ -127,35 +127,35 @@ _eselect () {
local globopts sedcmd modnames modopts
globopts=(
- "--no-colour[Disable coloured output]" \
- "--no-color[Disable coloured output]"
+ "--colour=no[Disable coloured output]" \
+ "--color=no[Disable coloured output]"
)
- modnames=(${${${(M)${(f)"$(eselect --no-color list-modules)"}## *}// */}// /})
+ modnames=(${${${(M)${(f)"$(eselect --color=no list-modules)"}## *}// */}// /})
if ((CURRENT == 2)); then
_arguments -s \
"$globopts[@]" \
"*:portage:_values 'eselect modules' \$modnames[@]" && return 0
elif ((CURRENT == 3)); then
- if [[ $words[2] == --no-colour || $words[2] == --no-color ]]; then
+ if [[ $words[2] == --colour=no || $words[2] == --color=no ]]; then
_arguments -s \
"*:portage:_values 'eselect modules' \$modnames[@]" && return 0
elif (( $modnames[(I)$words[2]] )); then
if [[ "$words[2]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
_eselect_$words[2] "$@"
else
- modopts=(${${${(M)${(f)"$(eselect --no-color $words[2] usage)"}## *}// */}// /})
+ modopts=(${${${(M)${(f)"$(eselect --color=no $words[2] usage)"}## *}// */}// /})
_arguments -s \
"*:portage:_values 'eselect $words[2] options' \$modopts[@]" && return 0
fi
fi
elif ((CURRENT >= 4)); then
- if (( $words[(I)(--no-color|--no-colour)] )); then
+ if (( $words[(I)(--color=no|--colour=no)] )); then
if (( $modnames[(I)$words[3]] )); then
if [[ "$words[3]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
_eselect_$words[3] "$@"
else
- modopts=(${${${${(M)${(f)"$(eselect --no-color $words[3] usage)"}## *}// */}// /}// *})
+ modopts=(${${${${(M)${(f)"$(eselect --color=no $words[3] usage)"}## *}// */}// /}// *})
_arguments -s \
"*:portage:_values 'eselect $words[3] options' \$modopts[@]" && return 0
fi
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-01-24 1:05 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-01-24 1:05 UTC (permalink / raw
To: gentoo-commits
commit: 7c594fdefba2aed0c294a144ff82329cdad3205a
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 24 01:02:27 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Jan 24 01:02:27 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=7c594fde
Fix indentation and whitespace
---
_eselect | 238 +++++++++++++++++++++++++++++++--------------------------------
1 file changed, 119 insertions(+), 119 deletions(-)
diff --git a/_eselect b/_eselect
index 0f0362b..9cc28a5 100644
--- a/_eselect
+++ b/_eselect
@@ -6,166 +6,166 @@ _eselect_env () {
"noldconfig[Do not alter the ld.so cache or configuration]" && return 0
fi
_values "env options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- 'update[Collect environment variables from all scripts]' && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ 'update[Collect environment variables from all scripts]' && return 0
}
_eselect_binutils () {
local binutilslist
- if (( $words[(I)(set)] )); then
- binutilslist=(${${${(M)${(f)"$(eselect --color=no binutils list)"}## *}// \**/}//( \[*\] | \[*\] )/})
- _values "available binutils version" $binutilslist[@] && return 0
- fi
+ if (( $words[(I)(set)] )); then
+ binutilslist=(${${${(M)${(f)"$(eselect --color=no binutils list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ _values "available binutils version" $binutilslist[@] && return 0
+ fi
_values "binutils options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List all installed version of binutils]" \
- "show[Print the currently active binutils version]" \
- "set[Activate one of the installed binutils]" && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List all installed version of binutils]" \
+ "show[Print the currently active binutils version]" \
+ "set[Activate one of the installed binutils]" && return 0
}
_eselect_kernel () {
local kernellist
- if (( $words[(I)(set)] )); then
- kernellist=(${${${(M)${(f)"$(eselect --color=no kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
- _values "available kernel version" $kernellist[@] && return 0
- fi
+ if (( $words[(I)(set)] )); then
+ kernellist=(${${${(M)${(f)"$(eselect --color=no kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ _values "available kernel version" $kernellist[@] && return 0
+ fi
_values "kenrel options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List available kernel symlink targets]" \
- "show[Show the current kernel symlink]" \
- "set[Set a new kernel symlink target]" && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List available kernel symlink targets]" \
+ "show[Show the current kernel symlink]" \
+ "set[Set a new kernel symlink target]" && return 0
}
_eselect_ctags () {
local ctagslist
- if (( $words[(I)(set)] )); then
- ctagslist=(${${${(M)${(f)"$(eselect --color=no ctags list)"}## *}// \**/}//( \[*\] | \[*\] )/})
- _values "available ctags version" $ctagslist[@] && return 0
- fi
+ if (( $words[(I)(set)] )); then
+ ctagslist=(${${${(M)${(f)"$(eselect --color=no ctags list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ _values "available ctags version" $ctagslist[@] && return 0
+ fi
_values "ctags options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List available ctags symlink targets]" \
- "show[Show the current target of the ctags symlink]" \
- "update[Automatically update the ctags symlink]" \
- "set[Set a new ctags symlink target]" && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List available ctags symlink targets]" \
+ "show[Show the current target of the ctags symlink]" \
+ "update[Automatically update the ctags symlink]" \
+ "set[Set a new ctags symlink target]" && return 0
}
_eselect_profile () {
local profilelist
- if (( $words[(I)(set)] )); then
- profilelist=(${${${(M)${(f)"$(eselect --color=no profile list)"}## *}// \**/}//( \[*\] | \[*\] )/})
- _values -w "available profiles" $profilelist[@] \
- "--force[Forcibly set the symlink]" && return 0
- fi
+ if (( $words[(I)(set)] )); then
+ profilelist=(${${${(M)${(f)"$(eselect --color=no profile list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ _values -w "available profiles" $profilelist[@] \
+ "--force[Forcibly set the symlink]" && return 0
+ fi
_values "profile options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List available profile symlink targets]" \
- "show[Show the current make.profile symlink]" \
- "set[Set a new profile symlink target]" && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List available profile symlink targets]" \
+ "show[Show the current make.profile symlink]" \
+ "set[Set a new profile symlink target]" && return 0
}
_eselect_fontconfig () {
local fclistenabled fclistdisabled
- if (( $words[(I)(enable)] )); then
- fclistdisabled=(${${${${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
- _values -w ".conf to enable" $fclistdisabled[@] && return 0
+ if (( $words[(I)(enable)] )); then
+ fclistdisabled=(${${${${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
+ _values -w ".conf to enable" $fclistdisabled[@] && return 0
elif (( $words[(I)(disable)] )); then
- fclistenabled=(${${${(M)${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
- _values -w ".conf to disable" $fclistenabled[@] && return 0
- fi
+ fclistenabled=(${${${(M)${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
+ _values -w ".conf to disable" $fclistenabled[@] && return 0
+ fi
_values "fontconfig options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List available fontconfig .conf files]" \
- "disable[Disable specified fontconfig .conf file(s)]" \
- "enable[Enable specified fontconfig .conf file(s)]" && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List available fontconfig .conf files]" \
+ "disable[Disable specified fontconfig .conf file(s)]" \
+ "enable[Enable specified fontconfig .conf file(s)]" && return 0
}
_eselect_opengl () {
local opengllist
if (( $words[(I)(set)] )); then
- opengllist=(${${${(M)${(f)"$(eselect --color=no opengl list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ opengllist=(${${${(M)${(f)"$(eselect --color=no opengl list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values -w "opengl implementations and options" $opengllist[@] \
- "--use-old[If an implementationis already set, use that one instead]" \
- "--prefix[Set the source prefix]:path:_files -/" \
- "--dst-prefix[Set the destination prefix]:path:_files -/" \
- "--impl-headers[Override global headers with ones provided by this profile]" && return 0
+ "--use-old[If an implementationis already set, use that one instead]" \
+ "--prefix[Set the source prefix]:path:_files -/" \
+ "--dst-prefix[Set the destination prefix]:path:_files -/" \
+ "--impl-headers[Override global headers with ones provided by this profile]" && return 0
fi
_values "opengl options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List the available OpenGL implementations]" \
- "set[Select the OpenGL implementation]" \
- "show[Print the current OpenGL implementation]" && return 0
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List the available OpenGL implementations]" \
+ "set[Select the OpenGL implementation]" \
+ "show[Print the current OpenGL implementation]" && return 0
}
_eselect_vi () {
local vilist
if (( $words[(I)(set)] )); then
- vilist=(${${${(M)${(f)"$(eselect --color=no vi list)"}## *}// \**/}//( \[*\] | \[*\] )/})
- _values -w "vi implementation" $vilist[@] && return 0
+ vilist=(${${${(M)${(f)"$(eselect --color=no vi list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ _values -w "vi implementation" $vilist[@] && return 0
elif (( $words[(I)(update)] )); then
- _values -w "option" "--if-unset[Do not override existing implementation]" && return 0
+ _values -w "option" "--if-unset[Do not override existing implementation]" && return 0
fi
_values "vi options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- "list[List available vi implementations]" \
- "set[Set a new vi implementation provider]" \
- "show[Show the current vi implementation]" \
- "update[Automatically update the vi provider]"
+ "help[Display help text]" \
+ "usage[Display usage information]" \
+ "version[Display version information]" \
+ "list[List available vi implementations]" \
+ "set[Set a new vi implementation provider]" \
+ "show[Show the current vi implementation]" \
+ "update[Automatically update the vi provider]"
}
_eselect () {
- local globopts sedcmd modnames modopts
+ local globopts sedcmd modnames modopts
- globopts=(
- "--colour=no[Disable coloured output]" \
- "--color=no[Disable coloured output]"
- )
- modnames=(${${${(M)${(f)"$(eselect --color=no modules list)"}## *}// */}// /})
+ globopts=(
+ "--colour=no[Disable coloured output]" \
+ "--color=no[Disable coloured output]"
+ )
+ modnames=(${${${(M)${(f)"$(eselect --color=no modules list)"}## *}// */}// /})
- if ((CURRENT == 2)); then
- _arguments -s \
- "$globopts[@]" \
- "*:portage:_values 'eselect modules' \$modnames[@]" && return 0
- elif ((CURRENT == 3)); then
- if [[ $words[2] == --colour=no || $words[2] == --color=no ]]; then
- _arguments -s \
- "*:portage:_values 'eselect modules' \$modnames[@]" && return 0
- elif (( $modnames[(I)$words[2]] )); then
- if [[ "$words[2]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
- _eselect_$words[2] "$@"
- else
- modopts=(${${${(M)${(f)"$(eselect --color=no $words[2] usage)"}## *}// */}// /})
- _arguments -s \
- "*:portage:_values 'eselect $words[2] options' \$modopts[@]" && return 0
- fi
- fi
- elif ((CURRENT >= 4)); then
- if (( $words[(I)(--color=no|--colour=no)] )); then
- if (( $modnames[(I)$words[3]] )); then
- if [[ "$words[3]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
- _eselect_$words[3] "$@"
- else
- modopts=(${${${${(M)${(f)"$(eselect --color=no $words[3] usage)"}## *}// */}// /}// *})
- _arguments -s \
- "*:portage:_values 'eselect $words[3] options' \$modopts[@]" && return 0
- fi
- fi
- else
- if (( $modnames[(I)$words[2]] )); then
- _eselect_$words[2] "$@"
- fi
- fi
- fi
+ if ((CURRENT == 2)); then
+ _arguments -s \
+ "$globopts[@]" \
+ "*:portage:_values 'eselect modules' \$modnames[@]" && return 0
+ elif ((CURRENT == 3)); then
+ if [[ $words[2] == --colour=no || $words[2] == --color=no ]]; then
+ _arguments -s \
+ "*:portage:_values 'eselect modules' \$modnames[@]" && return 0
+ elif (( $modnames[(I)$words[2]] )); then
+ if [[ "$words[2]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
+ _eselect_$words[2] "$@"
+ else
+ modopts=(${${${(M)${(f)"$(eselect --color=no $words[2] usage)"}## *}// */}// /})
+ _arguments -s \
+ "*:portage:_values 'eselect $words[2] options' \$modopts[@]" && return 0
+ fi
+ fi
+ elif ((CURRENT >= 4)); then
+ if (( $words[(I)(--color=no|--colour=no)] )); then
+ if (( $modnames[(I)$words[3]] )); then
+ if [[ "$words[3]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
+ _eselect_$words[3] "$@"
+ else
+ modopts=(${${${${(M)${(f)"$(eselect --color=no $words[3] usage)"}## *}// */}// /}// *})
+ _arguments -s \
+ "*:portage:_values 'eselect $words[3] options' \$modopts[@]" && return 0
+ fi
+ fi
+ else
+ if (( $modnames[(I)$words[2]] )); then
+ _eselect_$words[2] "$@"
+ fi
+ fi
+ fi
}
_eselect "$@"
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-01-24 1:05 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-01-24 1:05 UTC (permalink / raw
To: gentoo-commits
commit: 184ad6eaa972991a1690783d09a711cf55ee913e
Author: Vikraman Choudhury <vikraman <AT> gentoo <DOT> org>
AuthorDate: Thu Jan 23 22:47:17 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Jan 24 01:02:15 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=184ad6ea
Fix command for listing eselect modules
---
_eselect | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_eselect b/_eselect
index 5b15d50..0f0362b 100644
--- a/_eselect
+++ b/_eselect
@@ -130,7 +130,7 @@ _eselect () {
"--colour=no[Disable coloured output]" \
"--color=no[Disable coloured output]"
)
- modnames=(${${${(M)${(f)"$(eselect --color=no list-modules)"}## *}// */}// /})
+ modnames=(${${${(M)${(f)"$(eselect --color=no modules list)"}## *}// */}// /})
if ((CURRENT == 2)); then
_arguments -s \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-01-24 1:29 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-01-24 1:29 UTC (permalink / raw
To: gentoo-commits
commit: db2cd6cea4b03d4dbefed3c84833b5b534ee2f13
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 24 01:27:31 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Jan 24 01:28:07 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=db2cd6ce
create xz tarballs instead of bzip2
---
create-dist-bzip2.sh => create-dist-xz.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/create-dist-bzip2.sh b/create-dist-xz.sh
similarity index 90%
rename from create-dist-bzip2.sh
rename to create-dist-xz.sh
index c7699f7..b69967b 100755
--- a/create-dist-bzip2.sh
+++ b/create-dist-xz.sh
@@ -22,4 +22,4 @@ for i in ${COMPLETION_WIDGETS}; do
cp ${i} ${snapshot_dir}
done
-${TAR} -jcf ${snapshot_dir}.tar.bz2 ${snapshot_dir}
+${TAR} -Jcf ${snapshot_dir}.tar.xz ${snapshot_dir}
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:18 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:18 UTC (permalink / raw
To: gentoo-commits
commit: ced8384621cee9dd38668712d54dc68a2eb35d9a
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:08:20 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:08:20 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=ced83846
add license file (previously this info was only visible in the ebuilds)
---
COPYING | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff --git a/COPYING b/COPYING
new file mode 100644
index 0000000..24f1b73
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,25 @@
+The Z Shell is copyright (c) 1992-2001 Paul Falstad, Richard Coleman,
+Zoltán Hidvégi, Andrew Main, Peter Stephenson, Sven Wischnowsky, and
+others. All rights reserved. Individual authors, whether or not
+specifically named, retain copyright in all changes; in what follows, they
+are referred to as `the Zsh Development Group'. This is for convenience
+only and this body has no legal status. The Z shell is distributed under
+the following licence; any provisions made in individual files take
+precedence.
+
+Permission is hereby granted, without written agreement and without
+licence or royalty fees, to use, copy, modify, and distribute this
+software and to distribute modified versions of this software for any
+purpose, provided that the above copyright notice and the following
+two paragraphs appear in all copies of this software.
+
+In no event shall the Zsh Development Group be liable to any party for
+direct, indirect, special, incidental, or consequential damages arising out
+of the use of this software and its documentation, even if the Zsh
+Development Group have been advised of the possibility of such damage.
+
+The Zsh Development Group specifically disclaim any warranties, including,
+but not limited to, the implied warranties of merchantability and fitness
+for a particular purpose. The software provided hereunder is on an "as is"
+basis, and the Zsh Development Group have no obligation to provide
+maintenance, support, updates, enhancements, or modifications.
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:18 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:18 UTC (permalink / raw
To: gentoo-commits
commit: 967418687b3b4a2c721752acc633a84496149f97
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:16:07 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:16:07 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=96741868
fix spelling mistake
---
_portage_utils | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_portage_utils b/_portage_utils
index fc3b776..abd20c9 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -78,7 +78,7 @@ qlist)
;;
qlop)
_arguments -s $common_args \
- {'(--guage)-g','(-g)--guage'}'[Guage number of times a package has been merged]' \
+ {'(--gauge)-g','(-g)--gauge'}'[Gauge number of times a package has been merged]' \
{'(--time)-t','(-t)--time'}'[Calculate merge time for a specific package]' \
{'(--human)-H','(-H)--human'}'[Print seconds in human readable format (needs -t)]' \
{'(--list)-l','(-l)--list'}'[Show merge history]' \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:36 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:36 UTC (permalink / raw
To: gentoo-commits
commit: 0c9e182097dff78dca004ed877136667bd197576
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:34:47 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:34:47 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=0c9e1820
_portage_utils: update qlist options
---
_portage_utils | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/_portage_utils b/_portage_utils
index abd20c9..7cd05c1 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -67,13 +67,16 @@ qlist)
_arguments -s $common_args \
{'(--installed)-I','(-I)--installed'}'[Just show installed packages]' \
{'(--slots)-S','(-S)--slots'}'[Display installed packages with slots]' \
+ {'(--repo)-R','(-R)--repo'}'[Display installed packages with repository]' \
{'(--umap)-U','(-U)--umap'}'[Display installed packages with flags used]' \
- {'(--dups)-D','(-D)--dups'}'[Only show package dups]' \
+ {'(--columns)-c','(-c)--columns'}'[Display column view]' \
+ '--show-debug[Show /usr/lib/debug files]' \
{'(--exact)-e','(-e)--exact'}'[Exact match (only CAT/PN or PN without PV)]' \
{'(--all)-a','(-a)--all'}'[Show every installed package]' \
{'(--dir)-d','(-d)--dir'}'[Only show directories]' \
{'(--obj)-o','(-o)--obj'}'[Only show objects]' \
- {'(--sym)-s','(-s)--sy'}'[Only show symlinks]' \
+ {'(--sym)-s','(-s)--sym'}'[Only show symlinks]' \
+ '--root[Set the ROOT env var]:root directory:_files -/' \
'*:packages:_gentoo_packages installed'
;;
qlop)
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:42 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:42 UTC (permalink / raw
To: gentoo-commits
commit: e60675e939a9af7719f6a11ebee1223d2f79f83e
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:42:31 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:42:31 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=e60675e9
_portage_utils: fix whitespace
---
_portage_utils | 187 +++++++++++++++++++++++++++++----------------------------
1 file changed, 94 insertions(+), 93 deletions(-)
diff --git a/_portage_utils b/_portage_utils
index 7cd05c1..ead6ca0 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -4,12 +4,13 @@
#
local common_args PORTDIR
var=PORTDIR
+
[[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
-local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /etc/make.conf ]] &&
-local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
+ local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
[[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
-local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
+ local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
common_args=(
{'(--verbose)-v','(-v)--verbose'}'[Make a lot of noise]' \
@@ -18,37 +19,38 @@ common_args=(
{'(--help)-h','(-h)--help'}'[Print this help and exit]' \
{'(--version)-V','(-V)--version'}'[Print version and exit]' \
)
+
case $service in
qcheck)
_arguments -s $common_args \
- {'(--all)-a','(-a)--all'}'[List all packages]' \
- {'(--update)-u','(-u)--update'}'[Update chksum and mtimes for packages]' \
- '*:packages:_gentoo_packages installed'
+ {'(--all)-a','(-a)--all'}'[List all packages]' \
+ {'(--update)-u','(-u)--update'}'[Update chksum and mtimes for packages]' \
+ '*:packages:_gentoo_packages installed'
;;
qdepends)
_arguments -s $common_args \
- {'(--depend)-d','(-d)--depend'}'[Show DEPEND info (default)]' \
- {'(--rdepend)-r','(-r)--rdepend'}'[Show RDEPEND info]' \
- {'(--pdepend)-p','(-p)--pdepend'}'[Show PDEPEND info]' \
- {'(--key)-k','(-k)--key'}'[User defined vdb key]' \
- {'(--query)-Q','(-Q)--query'}'[Query reverse deps]' \
- {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
- {'(--all)-a','(-a)--all'}'[Show all DEPEND info]' \
- '*:packages:_gentoo_packages installed'
+ {'(--depend)-d','(-d)--depend'}'[Show DEPEND info (default)]' \
+ {'(--rdepend)-r','(-r)--rdepend'}'[Show RDEPEND info]' \
+ {'(--pdepend)-p','(-p)--pdepend'}'[Show PDEPEND info]' \
+ {'(--key)-k','(-k)--key'}'[User defined vdb key]' \
+ {'(--query)-Q','(-Q)--query'}'[Query reverse deps]' \
+ {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
+ {'(--all)-a','(-a)--all'}'[Show all DEPEND info]' \
+ '*:packages:_gentoo_packages installed'
;;
qfile)
- _arguments -s $common_args \
- {'(--exact)-e','(-e)--exact'}'[Exact match]' \
- '*:filename:_files'
+ _arguments -s $common_args \
+ {'(--exact)-e','(-e)--exact'}'[Exact match]' \
+ '*:filename:_files'
;;
qgrep)
- _arguments -s $common_args \
- {'(--invert-match)-I','(-I)--invert-match'}'[Select non-matching lines]' \
- {'(--ignore-case)-i','(-i)--ignore-case'}'[Ignore case distinctions]' \
- {'(--with-filename)-H','(-H)--with-filename'}'[Print the filename for each match]' \
- {'(--count)-c','(-c)--count'}'[Only print a count of matching lines per FILE]' \
- {'(--regexp)-e','(-e)--regexp'}'[Use PATTERN as a regular expression]' \
- '*:pattern::'
+ _arguments -s $common_args \
+ {'(--invert-match)-I','(-I)--invert-match'}'[Select non-matching lines]' \
+ {'(--ignore-case)-i','(-i)--ignore-case'}'[Ignore case distinctions]' \
+ {'(--with-filename)-H','(-H)--with-filename'}'[Print the filename for each match]' \
+ {'(--count)-c','(-c)--count'}'[Only print a count of matching lines per FILE]' \
+ {'(--regexp)-e','(-e)--regexp'}'[Use PATTERN as a regular expression]' \
+ '*:pattern::'
;;
qcache)
local arches allarches arch
@@ -58,91 +60,90 @@ qcache)
for arch in $arches;do
allarches=($allarches $arch)
done
- _describe -t available-arches "arch" allarches
+ _describe -t available-arches "arch" allarches
}
- _arguments -s $common_args \
- '*:arch:show_archs'
+ _arguments -s $common_args \
+ '*:arch:show_archs'
;;
qlist)
- _arguments -s $common_args \
- {'(--installed)-I','(-I)--installed'}'[Just show installed packages]' \
- {'(--slots)-S','(-S)--slots'}'[Display installed packages with slots]' \
- {'(--repo)-R','(-R)--repo'}'[Display installed packages with repository]' \
- {'(--umap)-U','(-U)--umap'}'[Display installed packages with flags used]' \
- {'(--columns)-c','(-c)--columns'}'[Display column view]' \
- '--show-debug[Show /usr/lib/debug files]' \
- {'(--exact)-e','(-e)--exact'}'[Exact match (only CAT/PN or PN without PV)]' \
- {'(--all)-a','(-a)--all'}'[Show every installed package]' \
- {'(--dir)-d','(-d)--dir'}'[Only show directories]' \
- {'(--obj)-o','(-o)--obj'}'[Only show objects]' \
- {'(--sym)-s','(-s)--sym'}'[Only show symlinks]' \
- '--root[Set the ROOT env var]:root directory:_files -/' \
- '*:packages:_gentoo_packages installed'
+ _arguments -s $common_args \
+ {'(--installed)-I','(-I)--installed'}'[Just show installed packages]' \
+ {'(--slots)-S','(-S)--slots'}'[Display installed packages with slots]' \
+ {'(--repo)-R','(-R)--repo'}'[Display installed packages with repository]' \
+ {'(--umap)-U','(-U)--umap'}'[Display installed packages with flags used]' \
+ {'(--columns)-c','(-c)--columns'}'[Display column view]' \
+ '--show-debug[Show /usr/lib/debug files]' \
+ {'(--exact)-e','(-e)--exact'}'[Exact match (only CAT/PN or PN without PV)]' \
+ {'(--all)-a','(-a)--all'}'[Show every installed package]' \
+ {'(--dir)-d','(-d)--dir'}'[Only show directories]' \
+ {'(--obj)-o','(-o)--obj'}'[Only show objects]' \
+ {'(--sym)-s','(-s)--sym'}'[Only show symlinks]' \
+ '--root[Set the ROOT env var]:root directory:_files -/' \
+ '*:packages:_gentoo_packages installed'
;;
qlop)
- _arguments -s $common_args \
- {'(--gauge)-g','(-g)--gauge'}'[Gauge number of times a package has been merged]' \
- {'(--time)-t','(-t)--time'}'[Calculate merge time for a specific package]' \
- {'(--human)-H','(-H)--human'}'[Print seconds in human readable format (needs -t)]' \
- {'(--list)-l','(-l)--list'}'[Show merge history]' \
- {'(--unlist)-u','(-u)--unlist'}'[Show unmerge history]' \
- {'(--sync)-s','(-s)--sync'}'[Show sync history]' \
- {'(--current)-c','(-c)--current'}'[Show current emerging packages]' \
- {'(--logfile)-f','(-f)--logfile'}'[Read emerge logfile instead of /var/log/emerge.log]:log:_files' \
- '*:packages:_gentoo_packages available'
+ _arguments -s $common_args \
+ {'(--gauge)-g','(-g)--gauge'}'[Gauge number of times a package has been merged]' \
+ {'(--time)-t','(-t)--time'}'[Calculate merge time for a specific package]' \
+ {'(--human)-H','(-H)--human'}'[Print seconds in human readable format (needs -t)]' \
+ {'(--list)-l','(-l)--list'}'[Show merge history]' \
+ {'(--unlist)-u','(-u)--unlist'}'[Show unmerge history]' \
+ {'(--sync)-s','(-s)--sync'}'[Show sync history]' \
+ {'(--current)-c','(-c)--current'}'[Show current emerging packages]' \
+ {'(--logfile)-f','(-f)--logfile'}'[Read emerge logfile instead of /var/log/emerge.log]:log:_files' \
+ '*:packages:_gentoo_packages available'
;;
qsearch)
- _arguments -s $common_args \
- {'(--all)-a','(-a)--all'}'[List the descriptions of every package in the cache]' \
- {'(--cache)-c','(-c)--cache'}'[Use the portage cache]' \
- {'(--search)-s','(-s)--search'}'[Regex search package basenames]' \
- {'(--desc)-S','(-S)--desc'}'[Regex search package descriptions]' \
- {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
- {'(--homepage)-H','(-H)--homepage'}'[Show homepage info]' \
- '*:pattern::'
+ _arguments -s $common_args \
+ {'(--all)-a','(-a)--all'}'[List the descriptions of every package in the cache]' \
+ {'(--cache)-c','(-c)--cache'}'[Use the portage cache]' \
+ {'(--search)-s','(-s)--search'}'[Regex search package basenames]' \
+ {'(--desc)-S','(-S)--desc'}'[Regex search package descriptions]' \
+ {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
+ {'(--homepage)-H','(-H)--homepage'}'[Show homepage info]' \
+ '*:pattern::'
;;
qsize)
- _arguments -s $common_args \
- {'(--filesystem)-f','(-f)--filesystem'}'[Show size used on disk]' \
- {'(--all)-a','(-a)--all'}'[Size all installed packages]' \
- {'(--sum)-s','(-s)--sum'}'[Include a summary]' \
- {'(--sum-only)-S','(-S)--sum-only'}'[Show just the summary]' \
- {'(--megabyte)-m','(-m)--megabyte'}'[Display size in megabytes]' \
- {'(--kilobyte)-k','(-k)--kilobyte'}'[Display size in kilobytes]' \
- {'(--byte)-b','(-b)--byte'}'[Display size in bytes]' \
- '*:packages:_gentoo_packages installed'
+ _arguments -s $common_args \
+ {'(--filesystem)-f','(-f)--filesystem'}'[Show size used on disk]' \
+ {'(--all)-a','(-a)--all'}'[Size all installed packages]' \
+ {'(--sum)-s','(-s)--sum'}'[Include a summary]' \
+ {'(--sum-only)-S','(-S)--sum-only'}'[Show just the summary]' \
+ {'(--megabyte)-m','(-m)--megabyte'}'[Display size in megabytes]' \
+ {'(--kilobyte)-k','(-k)--kilobyte'}'[Display size in kilobytes]' \
+ {'(--byte)-b','(-b)--byte'}'[Display size in bytes]' \
+ '*:packages:_gentoo_packages installed'
;;
quse)
- _arguments -s $common_args \
- {'(--exact)-e','(-e)--exact'}'[Show exact non regexp matching using strcmp]' \
- {'(--all)-a','(-a)--all'}'[Show annoying things in IUSE]' \
- {'(--keywords)-K','(-K)--keywords'}'[Use the KEYWORDS vs IUSE]' \
- {'(--license)-L','(-L)--license'}'[Use the LICENSE vs IUSE]' \
- {'(--describe)-D','(-D)--describe'}'[Describe the USE flag]' \
- {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
- '*:use flag:_gentoo_packages useflag'
+ _arguments -s $common_args \
+ {'(--exact)-e','(-e)--exact'}'[Show exact non regexp matching using strcmp]' \
+ {'(--all)-a','(-a)--all'}'[Show annoying things in IUSE]' \
+ {'(--keywords)-K','(-K)--keywords'}'[Use the KEYWORDS vs IUSE]' \
+ {'(--license)-L','(-L)--license'}'[Use the LICENSE vs IUSE]' \
+ {'(--describe)-D','(-D)--describe'}'[Describe the USE flag]' \
+ {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
+ '*:use flag:_gentoo_packages useflag'
;;
qtbz2)
- _arguments -s $common_args \
- {'(--join -s --split -t --tarbz2 -x --xpak)-j','(-t --tarbz2 -j -s --split -x --xpak)--join'}'[Join tar.bz2 + xpak into a tbz2]:*:tar.bz2 file and xpak file:_files -g \*.\(tar.bz2\|xpak\)' \
- {'(--join -j --split -t --tarbz2 -x --xpak)-s','(-t --tarbz2 -j --join -s -x --xpak)--split'}'[Split a tbz2 into a tar.bz2 + xpak]:tbz2 file:_files -g \*.tbz2' \
- {'(--join -j -s --split --tarbz2 -x --xpak)-t','(--join -j -s --split -t -x --xpak)--tarbz2'}'[Just split the tar.bz2]:tbz2 file:_files -g \*.tbz2' \
- {'(--join -j -s --split -t --tarbz2 --xpak)-x','(--join -j -s --split -t --tarbz2 -x)--xpak'}'[Just split the xpak]:tbz2 file:_files -g \*.tbz2' \
- {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
+ _arguments -s $common_args \
+ {'(--join -s --split -t --tarbz2 -x --xpak)-j','(-t --tarbz2 -j -s --split -x --xpak)--join'}'[Join tar.bz2 + xpak into a tbz2]:*:tar.bz2 file and xpak file:_files -g \*.\(tar.bz2\|xpak\)' \
+ {'(--join -j --split -t --tarbz2 -x --xpak)-s','(-t --tarbz2 -j --join -s -x --xpak)--split'}'[Split a tbz2 into a tar.bz2 + xpak]:tbz2 file:_files -g \*.tbz2' \
+ {'(--join -j -s --split --tarbz2 -x --xpak)-t','(--join -j -s --split -t -x --xpak)--tarbz2'}'[Just split the tar.bz2]:tbz2 file:_files -g \*.tbz2' \
+ {'(--join -j -s --split -t --tarbz2 --xpak)-x','(--join -j -s --split -t --tarbz2 -x)--xpak'}'[Just split the xpak]:tbz2 file:_files -g \*.tbz2' \
+ {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
;;
qpkg)
- _arguments -s $common_args \
- {'(--pretend)-p','(-p)--pretend'}'[pretend only]' \
- {'(--pkgdir)-P','(-P)--pkgdir'}'[alternate package directory]:alternate pkgdir:_files -/' \
- '*:Installed packages:_gentoo_packages installed_versions'
+ _arguments -s $common_args \
+ {'(--pretend)-p','(-p)--pretend'}'[pretend only]' \
+ {'(--pkgdir)-P','(-P)--pkgdir'}'[alternate package directory]:alternate pkgdir:_files -/' \
+ '*:Installed packages:_gentoo_packages installed_versions'
;;
qxpak)
- _arguments -s $common_args \
- {'(--list --extract -x --create -c)-l','(-l --extract -x --create -c)--list'}'[List the contents of an archive]:xpak archive:_files -g \*.xpak' \
- {'(--list -l --extract --create -c)-x','(--list -l -x --create -c)--extract'}'[Extract the contents of an archive]:xpak archive:_files -g \*.xpak' \
- {'(--list -l --extract -x --create)-c','(--list -l --extract -x -c)--create'}'[Create an archive of a directory/files]:*:archive name and files to archive:_files' \
- {'(--dir)-d','(-d)--dir'}'[Change to specified directory]:directory:_files -/' \
- {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
-
+ _arguments -s $common_args \
+ {'(--list --extract -x --create -c)-l','(-l --extract -x --create -c)--list'}'[List the contents of an archive]:xpak archive:_files -g \*.xpak' \
+ {'(--list -l --extract --create -c)-x','(--list -l -x --create -c)--extract'}'[Extract the contents of an archive]:xpak archive:_files -g \*.xpak' \
+ {'(--list -l --extract -x --create)-c','(--list -l --extract -x -c)--create'}'[Create an archive of a directory/files]:*:archive name and files to archive:_files' \
+ {'(--dir)-d','(-d)--dir'}'[Change to specified directory]:directory:_files -/' \
+ {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
;;
esac
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:59 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:59 UTC (permalink / raw
To: gentoo-commits
commit: e3fe6ff0ddc42aa20099c6aa01a87e8aea2a4605
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:52:56 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:59:22 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=e3fe6ff0
_portage_utils: indentation fixes
---
_portage_utils | 250 ++++++++++++++++++++++++++++-----------------------------
1 file changed, 125 insertions(+), 125 deletions(-)
diff --git a/_portage_utils b/_portage_utils
index ead6ca0..994c943 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -21,129 +21,129 @@ common_args=(
)
case $service in
-qcheck)
- _arguments -s $common_args \
- {'(--all)-a','(-a)--all'}'[List all packages]' \
- {'(--update)-u','(-u)--update'}'[Update chksum and mtimes for packages]' \
- '*:packages:_gentoo_packages installed'
-;;
-qdepends)
- _arguments -s $common_args \
- {'(--depend)-d','(-d)--depend'}'[Show DEPEND info (default)]' \
- {'(--rdepend)-r','(-r)--rdepend'}'[Show RDEPEND info]' \
- {'(--pdepend)-p','(-p)--pdepend'}'[Show PDEPEND info]' \
- {'(--key)-k','(-k)--key'}'[User defined vdb key]' \
- {'(--query)-Q','(-Q)--query'}'[Query reverse deps]' \
- {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
- {'(--all)-a','(-a)--all'}'[Show all DEPEND info]' \
- '*:packages:_gentoo_packages installed'
-;;
-qfile)
- _arguments -s $common_args \
- {'(--exact)-e','(-e)--exact'}'[Exact match]' \
- '*:filename:_files'
-;;
-qgrep)
- _arguments -s $common_args \
- {'(--invert-match)-I','(-I)--invert-match'}'[Select non-matching lines]' \
- {'(--ignore-case)-i','(-i)--ignore-case'}'[Ignore case distinctions]' \
- {'(--with-filename)-H','(-H)--with-filename'}'[Print the filename for each match]' \
- {'(--count)-c','(-c)--count'}'[Only print a count of matching lines per FILE]' \
- {'(--regexp)-e','(-e)--regexp'}'[Use PATTERN as a regular expression]' \
- '*:pattern::'
-;;
-qcache)
- local arches allarches arch
- show_archs(){
- arches=(${(f)"$(<$PORTDIR/profiles/arch.list)"})
- allarches=($archs)
- for arch in $arches;do
- allarches=($allarches $arch)
- done
- _describe -t available-arches "arch" allarches
- }
- _arguments -s $common_args \
- '*:arch:show_archs'
-;;
-qlist)
- _arguments -s $common_args \
- {'(--installed)-I','(-I)--installed'}'[Just show installed packages]' \
- {'(--slots)-S','(-S)--slots'}'[Display installed packages with slots]' \
- {'(--repo)-R','(-R)--repo'}'[Display installed packages with repository]' \
- {'(--umap)-U','(-U)--umap'}'[Display installed packages with flags used]' \
- {'(--columns)-c','(-c)--columns'}'[Display column view]' \
- '--show-debug[Show /usr/lib/debug files]' \
- {'(--exact)-e','(-e)--exact'}'[Exact match (only CAT/PN or PN without PV)]' \
- {'(--all)-a','(-a)--all'}'[Show every installed package]' \
- {'(--dir)-d','(-d)--dir'}'[Only show directories]' \
- {'(--obj)-o','(-o)--obj'}'[Only show objects]' \
- {'(--sym)-s','(-s)--sym'}'[Only show symlinks]' \
- '--root[Set the ROOT env var]:root directory:_files -/' \
- '*:packages:_gentoo_packages installed'
-;;
-qlop)
- _arguments -s $common_args \
- {'(--gauge)-g','(-g)--gauge'}'[Gauge number of times a package has been merged]' \
- {'(--time)-t','(-t)--time'}'[Calculate merge time for a specific package]' \
- {'(--human)-H','(-H)--human'}'[Print seconds in human readable format (needs -t)]' \
- {'(--list)-l','(-l)--list'}'[Show merge history]' \
- {'(--unlist)-u','(-u)--unlist'}'[Show unmerge history]' \
- {'(--sync)-s','(-s)--sync'}'[Show sync history]' \
- {'(--current)-c','(-c)--current'}'[Show current emerging packages]' \
- {'(--logfile)-f','(-f)--logfile'}'[Read emerge logfile instead of /var/log/emerge.log]:log:_files' \
- '*:packages:_gentoo_packages available'
-;;
-qsearch)
- _arguments -s $common_args \
- {'(--all)-a','(-a)--all'}'[List the descriptions of every package in the cache]' \
- {'(--cache)-c','(-c)--cache'}'[Use the portage cache]' \
- {'(--search)-s','(-s)--search'}'[Regex search package basenames]' \
- {'(--desc)-S','(-S)--desc'}'[Regex search package descriptions]' \
- {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
- {'(--homepage)-H','(-H)--homepage'}'[Show homepage info]' \
- '*:pattern::'
-;;
-qsize)
- _arguments -s $common_args \
- {'(--filesystem)-f','(-f)--filesystem'}'[Show size used on disk]' \
- {'(--all)-a','(-a)--all'}'[Size all installed packages]' \
- {'(--sum)-s','(-s)--sum'}'[Include a summary]' \
- {'(--sum-only)-S','(-S)--sum-only'}'[Show just the summary]' \
- {'(--megabyte)-m','(-m)--megabyte'}'[Display size in megabytes]' \
- {'(--kilobyte)-k','(-k)--kilobyte'}'[Display size in kilobytes]' \
- {'(--byte)-b','(-b)--byte'}'[Display size in bytes]' \
- '*:packages:_gentoo_packages installed'
-;;
-quse)
- _arguments -s $common_args \
- {'(--exact)-e','(-e)--exact'}'[Show exact non regexp matching using strcmp]' \
- {'(--all)-a','(-a)--all'}'[Show annoying things in IUSE]' \
- {'(--keywords)-K','(-K)--keywords'}'[Use the KEYWORDS vs IUSE]' \
- {'(--license)-L','(-L)--license'}'[Use the LICENSE vs IUSE]' \
- {'(--describe)-D','(-D)--describe'}'[Describe the USE flag]' \
- {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
- '*:use flag:_gentoo_packages useflag'
-;;
-qtbz2)
- _arguments -s $common_args \
- {'(--join -s --split -t --tarbz2 -x --xpak)-j','(-t --tarbz2 -j -s --split -x --xpak)--join'}'[Join tar.bz2 + xpak into a tbz2]:*:tar.bz2 file and xpak file:_files -g \*.\(tar.bz2\|xpak\)' \
- {'(--join -j --split -t --tarbz2 -x --xpak)-s','(-t --tarbz2 -j --join -s -x --xpak)--split'}'[Split a tbz2 into a tar.bz2 + xpak]:tbz2 file:_files -g \*.tbz2' \
- {'(--join -j -s --split --tarbz2 -x --xpak)-t','(--join -j -s --split -t -x --xpak)--tarbz2'}'[Just split the tar.bz2]:tbz2 file:_files -g \*.tbz2' \
- {'(--join -j -s --split -t --tarbz2 --xpak)-x','(--join -j -s --split -t --tarbz2 -x)--xpak'}'[Just split the xpak]:tbz2 file:_files -g \*.tbz2' \
- {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
-;;
-qpkg)
- _arguments -s $common_args \
- {'(--pretend)-p','(-p)--pretend'}'[pretend only]' \
- {'(--pkgdir)-P','(-P)--pkgdir'}'[alternate package directory]:alternate pkgdir:_files -/' \
- '*:Installed packages:_gentoo_packages installed_versions'
-;;
-qxpak)
- _arguments -s $common_args \
- {'(--list --extract -x --create -c)-l','(-l --extract -x --create -c)--list'}'[List the contents of an archive]:xpak archive:_files -g \*.xpak' \
- {'(--list -l --extract --create -c)-x','(--list -l -x --create -c)--extract'}'[Extract the contents of an archive]:xpak archive:_files -g \*.xpak' \
- {'(--list -l --extract -x --create)-c','(--list -l --extract -x -c)--create'}'[Create an archive of a directory/files]:*:archive name and files to archive:_files' \
- {'(--dir)-d','(-d)--dir'}'[Change to specified directory]:directory:_files -/' \
- {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
-;;
+ qcache)
+ local arches allarches arch
+ show_archs(){
+ arches=(${(f)"$(<$PORTDIR/profiles/arch.list)"})
+ allarches=($archs)
+ for arch in $arches;do
+ allarches=($allarches $arch)
+ done
+ _describe -t available-arches "arch" allarches
+ }
+ _arguments -s $common_args \
+ '*:arch:show_archs'
+ ;;
+ qcheck)
+ _arguments -s $common_args \
+ {'(--all)-a','(-a)--all'}'[List all packages]' \
+ {'(--update)-u','(-u)--update'}'[Update chksum and mtimes for packages]' \
+ '*:packages:_gentoo_packages installed'
+ ;;
+ qdepends)
+ _arguments -s $common_args \
+ {'(--depend)-d','(-d)--depend'}'[Show DEPEND info (default)]' \
+ {'(--rdepend)-r','(-r)--rdepend'}'[Show RDEPEND info]' \
+ {'(--pdepend)-p','(-p)--pdepend'}'[Show PDEPEND info]' \
+ {'(--key)-k','(-k)--key'}'[User defined vdb key]' \
+ {'(--query)-Q','(-Q)--query'}'[Query reverse deps]' \
+ {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
+ {'(--all)-a','(-a)--all'}'[Show all DEPEND info]' \
+ '*:packages:_gentoo_packages installed'
+ ;;
+ qfile)
+ _arguments -s $common_args \
+ {'(--exact)-e','(-e)--exact'}'[Exact match]' \
+ '*:filename:_files'
+ ;;
+ qgrep)
+ _arguments -s $common_args \
+ {'(--invert-match)-I','(-I)--invert-match'}'[Select non-matching lines]' \
+ {'(--ignore-case)-i','(-i)--ignore-case'}'[Ignore case distinctions]' \
+ {'(--with-filename)-H','(-H)--with-filename'}'[Print the filename for each match]' \
+ {'(--count)-c','(-c)--count'}'[Only print a count of matching lines per FILE]' \
+ {'(--regexp)-e','(-e)--regexp'}'[Use PATTERN as a regular expression]' \
+ '*:pattern::'
+ ;;
+ qlist)
+ _arguments -s $common_args \
+ {'(--installed)-I','(-I)--installed'}'[Just show installed packages]' \
+ {'(--slots)-S','(-S)--slots'}'[Display installed packages with slots]' \
+ {'(--repo)-R','(-R)--repo'}'[Display installed packages with repository]' \
+ {'(--umap)-U','(-U)--umap'}'[Display installed packages with flags used]' \
+ {'(--columns)-c','(-c)--columns'}'[Display column view]' \
+ '--show-debug[Show /usr/lib/debug files]' \
+ {'(--exact)-e','(-e)--exact'}'[Exact match (only CAT/PN or PN without PV)]' \
+ {'(--all)-a','(-a)--all'}'[Show every installed package]' \
+ {'(--dir)-d','(-d)--dir'}'[Only show directories]' \
+ {'(--obj)-o','(-o)--obj'}'[Only show objects]' \
+ {'(--sym)-s','(-s)--sym'}'[Only show symlinks]' \
+ '--root[Set the ROOT env var]:root directory:_files -/' \
+ '*:packages:_gentoo_packages installed'
+ ;;
+ qlop)
+ _arguments -s $common_args \
+ {'(--gauge)-g','(-g)--gauge'}'[Gauge number of times a package has been merged]' \
+ {'(--time)-t','(-t)--time'}'[Calculate merge time for a specific package]' \
+ {'(--human)-H','(-H)--human'}'[Print seconds in human readable format (needs -t)]' \
+ {'(--list)-l','(-l)--list'}'[Show merge history]' \
+ {'(--unlist)-u','(-u)--unlist'}'[Show unmerge history]' \
+ {'(--sync)-s','(-s)--sync'}'[Show sync history]' \
+ {'(--current)-c','(-c)--current'}'[Show current emerging packages]' \
+ {'(--logfile)-f','(-f)--logfile'}'[Read emerge logfile instead of /var/log/emerge.log]:log:_files' \
+ '*:packages:_gentoo_packages available'
+ ;;
+ qsearch)
+ _arguments -s $common_args \
+ {'(--all)-a','(-a)--all'}'[List the descriptions of every package in the cache]' \
+ {'(--cache)-c','(-c)--cache'}'[Use the portage cache]' \
+ {'(--search)-s','(-s)--search'}'[Regex search package basenames]' \
+ {'(--desc)-S','(-S)--desc'}'[Regex search package descriptions]' \
+ {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
+ {'(--homepage)-H','(-H)--homepage'}'[Show homepage info]' \
+ '*:pattern::'
+ ;;
+ qsize)
+ _arguments -s $common_args \
+ {'(--filesystem)-f','(-f)--filesystem'}'[Show size used on disk]' \
+ {'(--all)-a','(-a)--all'}'[Size all installed packages]' \
+ {'(--sum)-s','(-s)--sum'}'[Include a summary]' \
+ {'(--sum-only)-S','(-S)--sum-only'}'[Show just the summary]' \
+ {'(--megabyte)-m','(-m)--megabyte'}'[Display size in megabytes]' \
+ {'(--kilobyte)-k','(-k)--kilobyte'}'[Display size in kilobytes]' \
+ {'(--byte)-b','(-b)--byte'}'[Display size in bytes]' \
+ '*:packages:_gentoo_packages installed'
+ ;;
+ quse)
+ _arguments -s $common_args \
+ {'(--exact)-e','(-e)--exact'}'[Show exact non regexp matching using strcmp]' \
+ {'(--all)-a','(-a)--all'}'[Show annoying things in IUSE]' \
+ {'(--keywords)-K','(-K)--keywords'}'[Use the KEYWORDS vs IUSE]' \
+ {'(--license)-L','(-L)--license'}'[Use the LICENSE vs IUSE]' \
+ {'(--describe)-D','(-D)--describe'}'[Describe the USE flag]' \
+ {'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
+ '*:use flag:_gentoo_packages useflag'
+ ;;
+ qtbz2)
+ _arguments -s $common_args \
+ {'(--join -s --split -t --tarbz2 -x --xpak)-j','(-t --tarbz2 -j -s --split -x --xpak)--join'}'[Join tar.bz2 + xpak into a tbz2]:*:tar.bz2 file and xpak file:_files -g \*.\(tar.bz2\|xpak\)' \
+ {'(--join -j --split -t --tarbz2 -x --xpak)-s','(-t --tarbz2 -j --join -s -x --xpak)--split'}'[Split a tbz2 into a tar.bz2 + xpak]:tbz2 file:_files -g \*.tbz2' \
+ {'(--join -j -s --split --tarbz2 -x --xpak)-t','(--join -j -s --split -t -x --xpak)--tarbz2'}'[Just split the tar.bz2]:tbz2 file:_files -g \*.tbz2' \
+ {'(--join -j -s --split -t --tarbz2 --xpak)-x','(--join -j -s --split -t --tarbz2 -x)--xpak'}'[Just split the xpak]:tbz2 file:_files -g \*.tbz2' \
+ {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
+ ;;
+ qpkg)
+ _arguments -s $common_args \
+ {'(--pretend)-p','(-p)--pretend'}'[pretend only]' \
+ {'(--pkgdir)-P','(-P)--pkgdir'}'[alternate package directory]:alternate pkgdir:_files -/' \
+ '*:Installed packages:_gentoo_packages installed_versions'
+ ;;
+ qxpak)
+ _arguments -s $common_args \
+ {'(--list --extract -x --create -c)-l','(-l --extract -x --create -c)--list'}'[List the contents of an archive]:xpak archive:_files -g \*.xpak' \
+ {'(--list -l --extract --create -c)-x','(--list -l -x --create -c)--extract'}'[Extract the contents of an archive]:xpak archive:_files -g \*.xpak' \
+ {'(--list -l --extract -x --create)-c','(--list -l --extract -x -c)--create'}'[Create an archive of a directory/files]:*:archive name and files to archive:_files' \
+ {'(--dir)-d','(-d)--dir'}'[Change to specified directory]:directory:_files -/' \
+ {'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
+ ;;
esac
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:59 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:59 UTC (permalink / raw
To: gentoo-commits
commit: e6d1d0f5be822c30b97854fbf4504c9b4834c884
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:58:31 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:59:24 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=e6d1d0f5
_portage_utils: add qatom support
---
_portage_utils | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/_portage_utils b/_portage_utils
index 5ceae4e..5c0791d 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -22,6 +22,10 @@ common_args=(
)
case $service in
+ qatom)
+ _arguments -s $common_args \
+ {'(--compare)-c','(-c)--compare'}'[Compare two atoms]'
+ ;;
qcache)
local arches allarches arch
show_archs(){
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 18:59 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 18:59 UTC (permalink / raw
To: gentoo-commits
commit: f8132e8249f7c6814674dfe1be5039b1efe9112d
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 18:56:51 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 18:59:24 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=f8132e82
_portage_utils: move --root option to common_args
---
_portage_utils | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_portage_utils b/_portage_utils
index 994c943..5ceae4e 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -13,6 +13,7 @@ var=PORTDIR
local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
common_args=(
+ '--root[Set the ROOT env var]:root directory:_files -/' \
{'(--verbose)-v','(-v)--verbose'}'[Make a lot of noise]' \
{'(--quiet)-q','(-q)--quiet'}'[Tighter output; suppress warnings]' \
{'(--nocolor)-C','(-C)--nocolor'}'[Do not output color]' \
@@ -78,7 +79,6 @@ case $service in
{'(--dir)-d','(-d)--dir'}'[Only show directories]' \
{'(--obj)-o','(-o)--obj'}'[Only show objects]' \
{'(--sym)-s','(-s)--sym'}'[Only show symlinks]' \
- '--root[Set the ROOT env var]:root directory:_files -/' \
'*:packages:_gentoo_packages installed'
;;
qlop)
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-28 19:46 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-28 19:46 UTC (permalink / raw
To: gentoo-commits
commit: 7fde47696b589321e518ba389221634b8bb2dbb5
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 19:45:57 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 19:46:18 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=7fde4769
_portage_utils: update qcheck options
---
_portage_utils | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/_portage_utils b/_portage_utils
index 5c0791d..ae2d3ec 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -42,7 +42,15 @@ case $service in
qcheck)
_arguments -s $common_args \
{'(--all)-a','(-a)--all'}'[List all packages]' \
- {'(--update)-u','(-u)--update'}'[Update chksum and mtimes for packages]' \
+ {'(--exact)-e','(-e)--exact'}'[Exact match (only CAT/PN or PN without PV)]' \
+ {'(--skip)-s','(-s)--skip'}'[Ignore files matching regular expression]:regex' \
+ {'(--update)-u','(-u)--update'}'[Update missing files, chksum and mtimes for packages]' \
+ {'(--noafk)-A','(-A)--noafk'}'[Ignore missing files]' \
+ {'(--badonly)-B','(-B)--badonly'}'[Only print pkgs containing bad files]' \
+ {'(--nohash)-H','(-H)--nohash'}'[Ignore differing/unknown file chksums]' \
+ {'(--nomtime)-T','(-T)--nomtime'}'[Ignore differing file mtimes]' \
+ '--skip-protected[Ignore files in CONFIG_PROTECT-ed paths]' \
+ {'(--prelink)-p','(-p)--prelink'}'[Undo prelink when calculating checksums]' \
'*:packages:_gentoo_packages installed'
;;
qdepends)
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-29 1:41 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-29 1:41 UTC (permalink / raw
To: gentoo-commits
commit: d9c9ecc698f59eb006433234b910b80f6948d25f
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 29 01:39:18 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sat Mar 29 01:40:56 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=d9c9ecc6
_portage_utils: update to match remaining portage-utils-0.53 options
---
_portage_utils | 59 ++++++++++++++++++++++++++++++++++++++++++++--------------
1 file changed, 45 insertions(+), 14 deletions(-)
diff --git a/_portage_utils b/_portage_utils
index 94e82f6..a68be34 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -1,7 +1,7 @@
#compdef qatom qcache qcheck qdepends qfile qgrep qlist qlop qpkg qsearch qsize qtbz2 quse qxpak
-#portage-utils-0.19
-#
+# portage-utils-0.53
+
local common_args PORTDIR
var=PORTDIR
@@ -31,12 +31,20 @@ case $service in
show_archs(){
arches=(${(f)"$(<$PORTDIR/profiles/arch.list)"})
allarches=($archs)
- for arch in $arches;do
+ for arch in $arches; do
allarches=($allarches $arch)
done
_describe -t available-arches "arch" allarches
}
_arguments -s $common_args \
+ {'(--matchpkg)-p','(-p)--matchpkg'}'[match pkgname]:package name:_gentoo_packages available_pkgnames_only' \
+ {'(--matchcat)-c','(-c)--matchcat'}'[match catname]:category:_gentoo_packages category' \
+ {'(--imlate)-i','(-i)--imlate'}'[list packages that can be marked stable on a given arch]' \
+ {'(--dropped)-d','(-d)--dropped'}'[list packages that have dropped keywords on a version bump on a given arch]' \
+ {'(--testing)-t','(-t)--testing'}'[list packages that have ~arch versions, but no stable versions on a given arch]' \
+ {'(--stats)-s','(-s)--stats'}'[display statistics about the portage tree]' \
+ {'(--all)-a','(-a)--all'}'[list packages that have at least one version keyworded for on a given arch]' \
+ {'(--not)-n','(-n)--not'}"[list packages that aren't keyworded on a given arch]" \
'*:arch:show_archs'
;;
qcheck)
@@ -67,7 +75,14 @@ case $service in
;;
qfile)
_arguments -s $common_args \
- {'(--exact)-e','(-e)--exact'}'[Exact match]' \
+ {'(--slots)-S','(-S)--slots'}'[Display installed packages with slots]' \
+ {'(--root-prefix)-R','(-R)--root-prefix'}'[Assume arguments are already prefixed by $ROOT]' \
+ {'(--from)-f','(-f)--from'}'[Read arguments from file <arg> ("-" for stdin)]' \
+ {'(--max-args)-m','(-m)--max-args'}'[Treat from file arguments by groups of <arg> (defaults to 5000)]:number' \
+ {'(--basename)-b','(-b)--basename'}'[Match any component of the path]' \
+ {'(--orphans)-o','(-o)--orphans'}'[List orphan files]' \
+ {'(--exclude)-x','(-x)--exclude'}"[Don't look in package <arg> (used with --orphans)]:package:_gentoo_packages installed" \
+ {'(--exact)-e','(-e)--exact'}'[Exact match (used with --exclude)]' \
'*:filename:_files'
;;
qgrep)
@@ -75,8 +90,18 @@ case $service in
{'(--invert-match)-I','(-I)--invert-match'}'[Select non-matching lines]' \
{'(--ignore-case)-i','(-i)--ignore-case'}'[Ignore case distinctions]' \
{'(--with-filename)-H','(-H)--with-filename'}'[Print the filename for each match]' \
+ {'(--with-name)-N','(-N)--with-name'}'[Print the package or eclass name for each match]' \
{'(--count)-c','(-c)--count'}'[Only print a count of matching lines per FILE]' \
+ {'(--list)-l','(-l)--list'}'[Only print FILE names containing matches]' \
+ {'(--invert-list)-L','(-L)--invert-list'}'[Only print FILE names containing no match]' \
{'(--regexp)-e','(-e)--regexp'}'[Use PATTERN as a regular expression]' \
+ {'(--extended)-x','(-x)--extended'}'[Use PATTERN as an extended regular expression]' \
+ {'(--installed)-J','(-J)--installed'}'[Search in installed ebuilds instead of the tree]' \
+ {'(--eclass)-E','(-E)--eclass'}'[Search in eclasses instead of ebuilds]' \
+ {'(--skip-comments)-s','(-s)--skip-comments'}'[Skip comments lines]' \
+ {'(--skip)-S','(-S)--skip'}'[Skip lines matching <arg>]:pattern' \
+ {'(--before)-B','(-B)--before'}'[Print <arg> lines of leading context]:number' \
+ {'(--after)-A','(-A)--after'}'[Print <arg> lines of trailing context]:number' \
'*:pattern::'
;;
qlist)
@@ -110,6 +135,7 @@ case $service in
_arguments -s $common_args \
{'(--all)-a','(-a)--all'}'[List the descriptions of every package in the cache]' \
{'(--cache)-c','(-c)--cache'}'[Use the portage cache]' \
+ {'(--ebuilds)-e','(-e)--ebuilds'}'[Use the portage ebuild tree]' \
{'(--search)-s','(-s)--search'}'[Regex search package basenames]' \
{'(--desc)-S','(-S)--desc'}'[Regex search package descriptions]' \
{'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
@@ -122,9 +148,10 @@ case $service in
{'(--all)-a','(-a)--all'}'[Size all installed packages]' \
{'(--sum)-s','(-s)--sum'}'[Include a summary]' \
{'(--sum-only)-S','(-S)--sum-only'}'[Show just the summary]' \
- {'(--megabyte)-m','(-m)--megabyte'}'[Display size in megabytes]' \
- {'(--kilobyte)-k','(-k)--kilobyte'}'[Display size in kilobytes]' \
- {'(--byte)-b','(-b)--byte'}'[Display size in bytes]' \
+ {'(--megabytes)-m','(-m)--megabytes'}'[Display size in megabytes]' \
+ {'(--kilobytes)-k','(-k)--kilobytes'}'[Display size in kilobytes]' \
+ {'(--bytes)-b','(-b)--bytes'}'[Display size in bytes]' \
+ {'(--ignore)-i','(-i)--ignore'}'[Ignore regexp string]:pattern' \
'*:packages:_gentoo_packages installed'
;;
quse)
@@ -134,28 +161,32 @@ case $service in
{'(--keywords)-K','(-K)--keywords'}'[Use the KEYWORDS vs IUSE]' \
{'(--license)-L','(-L)--license'}'[Use the LICENSE vs IUSE]' \
{'(--describe)-D','(-D)--describe'}'[Describe the USE flag]' \
+ {'(--format)-F','(-F)--format'}'[Use your own variable formats: -F NAME=]:format' \
{'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
'*:use flag:_gentoo_packages useflag'
;;
qtbz2)
_arguments -s $common_args \
- {'(--join -s --split -t --tarbz2 -x --xpak)-j','(-t --tarbz2 -j -s --split -x --xpak)--join'}'[Join tar.bz2 + xpak into a tbz2]:*:tar.bz2 file and xpak file:_files -g \*.\(tar.bz2\|xpak\)' \
- {'(--join -j --split -t --tarbz2 -x --xpak)-s','(-t --tarbz2 -j --join -s -x --xpak)--split'}'[Split a tbz2 into a tar.bz2 + xpak]:tbz2 file:_files -g \*.tbz2' \
- {'(--join -j -s --split --tarbz2 -x --xpak)-t','(--join -j -s --split -t -x --xpak)--tarbz2'}'[Just split the tar.bz2]:tbz2 file:_files -g \*.tbz2' \
- {'(--join -j -s --split -t --tarbz2 --xpak)-x','(--join -j -s --split -t --tarbz2 -x)--xpak'}'[Just split the xpak]:tbz2 file:_files -g \*.tbz2' \
+ {'(--dir)-d','(-d)--dir'}'[Change to specified directory]:directory:_files -/' \
+ {'(--join)-j','(-j)--join'}'[Join tar.bz2 + xpak into a tbz2]:*:tar.bz2 file and xpak file:_files -g \*.\(tar.bz2\|xpak\)' \
+ {'(--split)-s','(-s)--split'}'[Split a tbz2 into a tar.bz2 + xpak]:tbz2 file:_files -g \*.tbz2' \
+ {'(--tarbz2)-t','(-t)--tarbz2'}'[Just split the tar.bz2]:tbz2 file:_files -g \*.tbz2' \
+ {'(--xpak)-x','(-x)--xpak'}'[Just split the xpak]:tbz2 file:_files -g \*.tbz2' \
{'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
;;
qpkg)
_arguments -s $common_args \
+ {'(--clean)-c','(-c)--clean'}'[clean pkgdir of unused binary files]' \
+ {'(--eclean)-E','(-E)--eclean'}'[clean pkgdir of files not in the tree anymore (slow)]' \
{'(--pretend)-p','(-p)--pretend'}'[pretend only]' \
{'(--pkgdir)-P','(-P)--pkgdir'}'[alternate package directory]:alternate pkgdir:_files -/' \
'*:Installed packages:_gentoo_packages installed_versions'
;;
qxpak)
_arguments -s $common_args \
- {'(--list --extract -x --create -c)-l','(-l --extract -x --create -c)--list'}'[List the contents of an archive]:xpak archive:_files -g \*.xpak' \
- {'(--list -l --extract --create -c)-x','(--list -l -x --create -c)--extract'}'[Extract the contents of an archive]:xpak archive:_files -g \*.xpak' \
- {'(--list -l --extract -x --create)-c','(--list -l --extract -x -c)--create'}'[Create an archive of a directory/files]:*:archive name and files to archive:_files' \
+ {'(--list)-l','(-l)--list'}'[List the contents of an archive]:xpak archive:_files -g \*.xpak' \
+ {'(--extract)-x','(-x)--extract'}'[Extract the contents of an archive]:xpak archive:_files -g \*.xpak' \
+ {'(--create)-c','(-c)--create'}'[Create an archive of a directory/files]:*:archive name and files to archive:_files' \
{'(--dir)-d','(-d)--dir'}'[Change to specified directory]:directory:_files -/' \
{'(--stdout)-O','(-O)--stdout'}'[Write files to stdout]'
;;
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-29 1:41 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-29 1:41 UTC (permalink / raw
To: gentoo-commits
commit: 4fa38b204cb0f036dcf451924eaf0b9411331f99
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 19:48:27 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 19:48:27 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=4fa38b20
_portage_utils: sort command list
---
_portage_utils | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_portage_utils b/_portage_utils
index ae2d3ec..3fe2bc7 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -1,4 +1,4 @@
-#compdef qatom qcheck qdepends qfile qgrep qcache qlist qlop qsearch qsize quse qtbz2 qpkg qxpak
+#compdef qatom qcache qcheck qdepends qfile qgrep qlist qlop qpkg qsearch qsize qtbz2 quse qxpak
#portage-utils-0.19
#
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-29 1:41 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-29 1:41 UTC (permalink / raw
To: gentoo-commits
commit: d5bab86685f91d8e4aa2d60c3063de8971ea6fa8
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 28 20:00:14 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Fri Mar 28 20:00:14 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=d5bab866
_portage_utils: update qdepends options
---
_portage_utils | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/_portage_utils b/_portage_utils
index 3fe2bc7..94e82f6 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -58,10 +58,11 @@ case $service in
{'(--depend)-d','(-d)--depend'}'[Show DEPEND info (default)]' \
{'(--rdepend)-r','(-r)--rdepend'}'[Show RDEPEND info]' \
{'(--pdepend)-p','(-p)--pdepend'}'[Show PDEPEND info]' \
- {'(--key)-k','(-k)--key'}'[User defined vdb key]' \
+ {'(--key)-k','(-k)--key'}'[User defined vdb key]:vdb key' \
{'(--query)-Q','(-Q)--query'}'[Query reverse deps]' \
{'(--name-only)-N','(-N)--name-only'}'[Only show package name]' \
{'(--all)-a','(-a)--all'}'[Show all DEPEND info]' \
+ {'(--format)-f','(-f)--format'}'[Pretty format specified depend strings]' \
'*:packages:_gentoo_packages installed'
;;
qfile)
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-29 2:35 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-29 2:35 UTC (permalink / raw
To: gentoo-commits
commit: bfde5e4653b1a4e53935326741d6bd162186659d
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 29 02:34:23 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sat Mar 29 02:34:23 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=bfde5e46
_portage_utils: fix arch list to skip comments
---
_portage_utils | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/_portage_utils b/_portage_utils
index a68be34..dc0d918 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -27,15 +27,17 @@ case $service in
{'(--compare)-c','(-c)--compare'}'[Compare two atoms]'
;;
qcache)
- local arches allarches arch
+ local arch
+ local -a arches allarches
+
show_archs(){
arches=(${(f)"$(<$PORTDIR/profiles/arch.list)"})
- allarches=($archs)
for arch in $arches; do
- allarches=($allarches $arch)
+ [[ $arch =~ '^[^#]' ]] && allarches+=( $arch )
done
_describe -t available-arches "arch" allarches
}
+
_arguments -s $common_args \
{'(--matchpkg)-p','(-p)--matchpkg'}'[match pkgname]:package name:_gentoo_packages available_pkgnames_only' \
{'(--matchcat)-c','(-c)--matchcat'}'[match catname]:category:_gentoo_packages category' \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-29 8:38 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-29 8:38 UTC (permalink / raw
To: gentoo-commits
commit: 454ecdae27518ef131ee4d42c446dea9ee01386b
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 29 08:22:33 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sat Mar 29 08:38:08 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=454ecdae
move _baselayout to _openrc and update existing support for openrc-0.12.4
---
_baselayout | 80 -------------------------------------------------------------
_openrc | 60 ++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 60 insertions(+), 80 deletions(-)
diff --git a/_baselayout b/_baselayout
deleted file mode 100644
index 9ff8360..0000000
--- a/_baselayout
+++ /dev/null
@@ -1,80 +0,0 @@
-#compdef rc-update rc-status rc
-
-# baselayout 1.12.11.1
-#
-# rc (fully done)
-# rc-update (fully done)
-# rc-status (fully done)
-
-
-local gentoo_runlevels
-gentoo_runlevels=(/etc/runlevels/*(:t))
-
-
-# Stuff for rc
-_rc () {
- if (( CURRENT == 2 )); then
- _values "runlevels" $gentoo_runlevels
- fi
-}
-
-
-# Stuff for rc-status
-_rc-status () {
- _arguments -s \
- {'(--all)-a','(-a)--all'}'[Show services at all run levels]' \
- {'(--list)-l','(-l)--list'}'[Show list of run levels]' \
- {'(--nocolor)-nc','(-nc)--nocolor'}'[Disable color output]' \
- {'(--servicelist)-s','(-s)--servicelist'}'[Show all services]' \
- {'(--unused)-u','(-u)--unused'}'[Show services not assigned to any run level]'
-
- _values 'runlevels' $gentoo_runlevels
-}
-
-
-# Stuff for rc-update
-_rc-update () {
- local used_init
-
- used_init=(${=${(M)${(f)"$(rc-update show 2>/dev/null)"}:#*|*[a-z]*}% |*})
-
- if (( CURRENT == 2 )); then
- _values "rc-update actions" \
- 'add[Add script to a runlevel]' \
- 'del[Delete script from a runlevel]' \
- 'show[Show scripts lanched at a runlevel]' \
- '-a[Add script to a runlevel]' \
- '-d[Delete script from a runlevel]' \
- '-s[Show scripts lanched at a runlevel]'
- elif (( CURRENT == 3 )); then
- case "$words[2]" in
- add|-a)
- _values "scripts" /etc/init.d/*~*.sh(:t)
- ;;
- del|-d)
- _values "scripts" $used_init
- ;;
- show|-s)
- _values "runlevels" $gentoo_runlevels \
- '-v[Show all init scripts]' \
- '--verbose[Show all init scripts]'
- ;;
- esac
- elif (( CURRENT == 4 )); then
- _values "runlevels" $gentoo_runlevels
- fi
-}
-
-
-case "$service" in
- rc-update)
- _rc-update "$@" && return 0
- ;;
- rc-status)
- _rc-status "$@" && return 0
- ;;
- rc)
- _rc "$@" && return 0
- ;;
-esac
-
diff --git a/_openrc b/_openrc
new file mode 100644
index 0000000..fd3259d
--- /dev/null
+++ b/_openrc
@@ -0,0 +1,60 @@
+#compdef rc-update rc-status rc
+
+# openrc-0.12.4
+
+local gentoo_runlevels
+gentoo_runlevels=(/etc/runlevels/*(:t))
+
+case "$service" in
+ rc-update)
+ local used_init
+ used_init=(${=${(M)${(f)"$(/sbin/rc-update show 2>/dev/null)"}:#*|*[a-z]*}% |*})
+
+ if (( CURRENT == 2 )); then
+ _values "rc-update actions" \
+ 'add[Add script to a runlevel]' \
+ 'del[Delete script from a runlevel]' \
+ 'show[Show scripts lanched at a runlevel]' \
+ '-a[Add script to a runlevel]' \
+ '-d[Delete script from a runlevel]' \
+ '-s[Show scripts lanched at a runlevel]'
+ elif (( CURRENT == 3 )); then
+ case "$words[2]" in
+ add|-a)
+ _values "service" /etc/init.d/*~*.sh(:t)
+ ;;
+ del|-d)
+ _values "service" $used_init
+ ;;
+ show|-s)
+ _values "runlevels" $gentoo_runlevels \
+ '-v[Show all init scripts]' \
+ '--verbose[Show all init scripts]'
+ ;;
+ esac
+ elif (( CURRENT == 4 )); then
+ _values "runlevels" $gentoo_runlevels
+ fi
+ ;;
+ rc-status)
+ _arguments -s \
+ {'(--all)-a','(-a)--all'}'[Show services at all runlevels]' \
+ {'(--crashed)-c','(-c)--crashed'}'[Show crashed services]' \
+ {'(--list)-l','(-l)--list'}'[Show list of runlevels]' \
+ {'(--runlevel)-r','(-r)--runlevel'}'[Show the name of the current runlevel]' \
+ {'(--servicelist)-s','(-s)--servicelist'}'[Show all services]' \
+ {'(--unused)-u','(-u)--unused'}'[Show services not assigned to any run level]' \
+ {'(--help)-h','(-h)--help'}'[Print this help output]' \
+ {'(--nocolor)-C','(-C)--nocolor'}'[Disable color output]' \
+ {'(--version)-V','(-V)--version'}'[Display software version]' \
+ {'(--verbose)-v','(-v)--verbose'}'[Run verbosely]' \
+ {'(--quiet)-q','(-q)--quiet'}'[Run quietly (Does not affect errors)]'
+
+ _values 'runlevels' $gentoo_runlevels
+ ;;
+ rc)
+ if (( CURRENT == 2 )); then
+ _values "runlevels" $gentoo_runlevels
+ fi
+ ;;
+esac
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: 6082841d566be1f017b6039c58242c553412fdeb
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 10:29:51 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 10:29:51 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=6082841d
_eselect: remove unused variable and fix indentation
---
_eselect | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/_eselect b/_eselect
index 57d11a9..5d75196 100644
--- a/_eselect
+++ b/_eselect
@@ -9,8 +9,8 @@ common_values=(
_eselect_env () {
if (( $words[(I)(update)] )); then
_values "update options" \
- "makelinks[force updating of links]" \
- "noldconfig[Do not alter the ld.so cache or configuration]" && return 0
+ "makelinks[force updating of links]" \
+ "noldconfig[Do not alter the ld.so cache or configuration]" && return 0
fi
_values "env options" $common_values \
'update[Collect environment variables from all scripts in /etc/env.d/]' && return 0
@@ -58,7 +58,7 @@ _eselect_profile () {
if (( $words[(I)(set)] )); then
profilelist=(${${${(M)${(f)"$(eselect --color=no profile list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values -w "available profiles" $profilelist[@] \
- "--force[Forcibly set the symlink]" && return 0
+ "--force[Forcibly set the symlink]" && return 0
fi
_values "profile options" $common_values \
"list[List available profile symlink targets]" \
@@ -113,7 +113,7 @@ _eselect_vi () {
}
_eselect () {
- local globopts sedcmd modnames modopts
+ local globopts modnames modopts
globopts=(
"--colour=no[Disable coloured output]"
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: 6f788576f1c9c2030d7c167aca52e32c66821396
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 10:35:17 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 10:35:17 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=6f788576
_eselect: use --brief option to simplify value parsing
---
_eselect | 19 ++++++++++---------
1 file changed, 10 insertions(+), 9 deletions(-)
diff --git a/_eselect b/_eselect
index 5d75196..702bf4c 100644
--- a/_eselect
+++ b/_eselect
@@ -19,7 +19,7 @@ _eselect_env () {
_eselect_binutils () {
local binutilslist
if (( $words[(I)(set)] )); then
- binutilslist=(${${${(M)${(f)"$(eselect --color=no binutils list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ binutilslist=(${(f)"$(eselect --brief --color=no binutils list)"})
_values "available binutils version" $binutilslist[@] && return 0
fi
_values "binutils options" $common_values \
@@ -31,7 +31,7 @@ _eselect_binutils () {
_eselect_kernel () {
local kernellist
if (( $words[(I)(set)] )); then
- kernellist=(${${${(M)${(f)"$(eselect --color=no kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ kernellist=(${(f)"$(eselect --brief --color=no kernel list)"})
_values "available kernel version" $kernellist[@] && return 0
fi
_values "kernel options" $common_values \
@@ -43,7 +43,7 @@ _eselect_kernel () {
_eselect_ctags () {
local ctagslist
if (( $words[(I)(set)] )); then
- ctagslist=(${${${(M)${(f)"$(eselect --color=no ctags list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ ctagslist=(${(f)"$(eselect --brief --color=no ctags list)"})
_values "available ctags version" $ctagslist[@] && return 0
fi
_values "ctags options" $common_values \
@@ -56,7 +56,7 @@ _eselect_ctags () {
_eselect_profile () {
local profilelist
if (( $words[(I)(set)] )); then
- profilelist=(${${${(M)${(f)"$(eselect --color=no profile list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ profilelist=(${(f)"$(eselect --brief --color=no profile list)"})
_values -w "available profiles" $profilelist[@] \
"--force[Forcibly set the symlink]" && return 0
fi
@@ -84,7 +84,7 @@ _eselect_fontconfig () {
_eselect_opengl () {
local opengllist
if (( $words[(I)(set)] )); then
- opengllist=(${${${(M)${(f)"$(eselect --color=no opengl list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ opengllist=(${(f)"$(eselect --brief --color=no opengl list)"})
_values -w "opengl implementations and options" $opengllist[@] \
"--use-old[If an implementation is already set, use that one instead]" \
"--prefix[Set the source prefix]:path:_files -/" \
@@ -100,7 +100,7 @@ _eselect_opengl () {
_eselect_vi () {
local vilist
if (( $words[(I)(set)] )); then
- vilist=(${${${(M)${(f)"$(eselect --color=no vi list)"}## *}// \**/}//( \[*\] | \[*\] )/})
+ vilist=(${(f)"$(eselect --brief --color=no vi list)"})
_values -w "vi implementation" $vilist[@] && return 0
elif (( $words[(I)(update)] )); then
_values -w "option" "--if-unset[Do not override existing implementation]" && return 0
@@ -116,10 +116,11 @@ _eselect () {
local globopts modnames modopts
globopts=(
+ "--brief[Make output shorter]"
"--colour=no[Disable coloured output]"
"--color=no[Disable coloured output]"
)
- modnames=(${${${(M)${(f)"$(eselect --color=no modules list)"}## *}// */}// /})
+ modnames=(${${${(M)${(f)"$(eselect --brief --color=no modules list)"}## *}// */}// /})
if ((CURRENT == 2)); then
_arguments -s \
@@ -133,7 +134,7 @@ _eselect () {
if [[ "$words[2]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
_eselect_$words[2] "$@"
else
- modopts=(${${${(M)${(f)"$(eselect --color=no $words[2] usage)"}## *}// */}// /})
+ modopts=(${${${(M)${(f)"$(eselect --brief --color=no $words[2] usage)"}## *}// */}// /})
_arguments -s \
"*:portage:_values 'eselect $words[2] options' \$modopts[@]" && return 0
fi
@@ -144,7 +145,7 @@ _eselect () {
if [[ "$words[3]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
_eselect_$words[3] "$@"
else
- modopts=(${${${${(M)${(f)"$(eselect --color=no $words[3] usage)"}## *}// */}// /}// *})
+ modopts=(${${${${(M)${(f)"$(eselect --brief --color=no $words[3] usage)"}## *}// */}// /}// *})
_arguments -s \
"*:portage:_values 'eselect $words[3] options' \$modopts[@]" && return 0
fi
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: e35d24bde64e76f326f9f46ea380c0f97db70ee9
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 08:44:41 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 08:44:41 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=e35d24bd
_eselect: don't duplicate common values
---
_eselect | 49 ++++++++++++++++---------------------------------
1 file changed, 16 insertions(+), 33 deletions(-)
diff --git a/_eselect b/_eselect
index 9cc28a5..37a71a8 100644
--- a/_eselect
+++ b/_eselect
@@ -1,15 +1,19 @@
#compdef eselect
+
+common_values=(
+ "help[Display help text]"
+ "usage[Display usage information]"
+ "version[Display version information]"
+)
+
_eselect_env () {
if (( $words[(I)(update)] )); then
_values "update options" \
"makelinks[force updating of links]" \
"noldconfig[Do not alter the ld.so cache or configuration]" && return 0
fi
- _values "env options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
- 'update[Collect environment variables from all scripts]' && return 0
+ _values "env options" $common_values \
+ 'update[Collect environment variables from all scripts in /etc/env.d/]' && return 0
}
_eselect_binutils () {
@@ -18,10 +22,7 @@ _eselect_binutils () {
binutilslist=(${${${(M)${(f)"$(eselect --color=no binutils list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available binutils version" $binutilslist[@] && return 0
fi
- _values "binutils options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "binutils options" $common_values \
"list[List all installed version of binutils]" \
"show[Print the currently active binutils version]" \
"set[Activate one of the installed binutils]" && return 0
@@ -33,10 +34,7 @@ _eselect_kernel () {
kernellist=(${${${(M)${(f)"$(eselect --color=no kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available kernel version" $kernellist[@] && return 0
fi
- _values "kenrel options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "kenrel options" $common_values \
"list[List available kernel symlink targets]" \
"show[Show the current kernel symlink]" \
"set[Set a new kernel symlink target]" && return 0
@@ -47,10 +45,7 @@ _eselect_ctags () {
ctagslist=(${${${(M)${(f)"$(eselect --color=no ctags list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available ctags version" $ctagslist[@] && return 0
fi
- _values "ctags options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "ctags options" $common_values \
"list[List available ctags symlink targets]" \
"show[Show the current target of the ctags symlink]" \
"update[Automatically update the ctags symlink]" \
@@ -63,10 +58,7 @@ _eselect_profile () {
_values -w "available profiles" $profilelist[@] \
"--force[Forcibly set the symlink]" && return 0
fi
- _values "profile options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "profile options" $common_values \
"list[List available profile symlink targets]" \
"show[Show the current make.profile symlink]" \
"set[Set a new profile symlink target]" && return 0
@@ -80,10 +72,7 @@ _eselect_fontconfig () {
fclistenabled=(${${${(M)${(M)${(f)"$(eselect --color=no fontconfig list)"}## *}#*\*}// \**/}//( \[*\] | \[*\] )/})
_values -w ".conf to disable" $fclistenabled[@] && return 0
fi
- _values "fontconfig options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "fontconfig options" $common_values \
"list[List available fontconfig .conf files]" \
"disable[Disable specified fontconfig .conf file(s)]" \
"enable[Enable specified fontconfig .conf file(s)]" && return 0
@@ -98,10 +87,7 @@ _eselect_opengl () {
"--dst-prefix[Set the destination prefix]:path:_files -/" \
"--impl-headers[Override global headers with ones provided by this profile]" && return 0
fi
- _values "opengl options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "opengl options" $common_values \
"list[List the available OpenGL implementations]" \
"set[Select the OpenGL implementation]" \
"show[Print the current OpenGL implementation]" && return 0
@@ -114,10 +100,7 @@ _eselect_vi () {
elif (( $words[(I)(update)] )); then
_values -w "option" "--if-unset[Do not override existing implementation]" && return 0
fi
- _values "vi options" \
- "help[Display help text]" \
- "usage[Display usage information]" \
- "version[Display version information]" \
+ _values "vi options" $common_values \
"list[List available vi implementations]" \
"set[Set a new vi implementation provider]" \
"show[Show the current vi implementation]" \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: 6168d1691081c4566fe1ba9903dba0d163b1efcc
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 10:53:57 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 10:53:57 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=6168d169
_eselect: escape colons in profile list
Zsh uses colons in completion values to separate field names and values
so the profiles with unescaped colons don't show up for completion.
---
_eselect | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_eselect b/_eselect
index 702bf4c..ae105d5 100644
--- a/_eselect
+++ b/_eselect
@@ -56,7 +56,7 @@ _eselect_ctags () {
_eselect_profile () {
local profilelist
if (( $words[(I)(set)] )); then
- profilelist=(${(f)"$(eselect --brief --color=no profile list)"})
+ profilelist=(${${(f)"$(eselect --brief --color=no profile list)"}/:/\\:})
_values -w "available profiles" $profilelist[@] \
"--force[Forcibly set the symlink]" && return 0
fi
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: ec5d89bfe46ee17b0c22a27a6ba8f48af8a628cc
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 08:56:25 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 08:56:25 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=ec5d89bf
_eselect: fix minor spelling and indentation issues
---
_eselect | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/_eselect b/_eselect
index c659dd5..57d11a9 100644
--- a/_eselect
+++ b/_eselect
@@ -34,7 +34,7 @@ _eselect_kernel () {
kernellist=(${${${(M)${(f)"$(eselect --color=no kernel list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values "available kernel version" $kernellist[@] && return 0
fi
- _values "kenrel options" $common_values \
+ _values "kernel options" $common_values \
"list[List available kernel symlink targets]" \
"show[Show the current kernel symlink]" \
"set[Set a new kernel symlink target]" && return 0
@@ -86,7 +86,7 @@ _eselect_opengl () {
if (( $words[(I)(set)] )); then
opengllist=(${${${(M)${(f)"$(eselect --color=no opengl list)"}## *}// \**/}//( \[*\] | \[*\] )/})
_values -w "opengl implementations and options" $opengllist[@] \
- "--use-old[If an implementationis already set, use that one instead]" \
+ "--use-old[If an implementation is already set, use that one instead]" \
"--prefix[Set the source prefix]:path:_files -/" \
"--dst-prefix[Set the destination prefix]:path:_files -/" \
"--impl-headers[Override global headers with ones provided by this profile]" && return 0
@@ -116,8 +116,8 @@ _eselect () {
local globopts sedcmd modnames modopts
globopts=(
- "--colour=no[Disable coloured output]" \
- "--color=no[Disable coloured output]"
+ "--colour=no[Disable coloured output]"
+ "--color=no[Disable coloured output]"
)
modnames=(${${${(M)${(f)"$(eselect --color=no modules list)"}## *}// */}// /})
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: 01576f1265e9cbb870483fdc196b807136d8346a
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 08:49:41 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 08:49:41 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=01576f12
_eselect: function spacing consistency
---
_eselect | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/_eselect b/_eselect
index 37a71a8..c659dd5 100644
--- a/_eselect
+++ b/_eselect
@@ -39,6 +39,7 @@ _eselect_kernel () {
"show[Show the current kernel symlink]" \
"set[Set a new kernel symlink target]" && return 0
}
+
_eselect_ctags () {
local ctagslist
if (( $words[(I)(set)] )); then
@@ -51,6 +52,7 @@ _eselect_ctags () {
"update[Automatically update the ctags symlink]" \
"set[Set a new ctags symlink target]" && return 0
}
+
_eselect_profile () {
local profilelist
if (( $words[(I)(set)] )); then
@@ -63,6 +65,7 @@ _eselect_profile () {
"show[Show the current make.profile symlink]" \
"set[Set a new profile symlink target]" && return 0
}
+
_eselect_fontconfig () {
local fclistenabled fclistdisabled
if (( $words[(I)(enable)] )); then
@@ -77,6 +80,7 @@ _eselect_fontconfig () {
"disable[Disable specified fontconfig .conf file(s)]" \
"enable[Enable specified fontconfig .conf file(s)]" && return 0
}
+
_eselect_opengl () {
local opengllist
if (( $words[(I)(set)] )); then
@@ -92,6 +96,7 @@ _eselect_opengl () {
"set[Select the OpenGL implementation]" \
"show[Print the current OpenGL implementation]" && return 0
}
+
_eselect_vi () {
local vilist
if (( $words[(I)(set)] )); then
@@ -106,6 +111,7 @@ _eselect_vi () {
"show[Show the current vi implementation]" \
"update[Automatically update the vi provider]"
}
+
_eselect () {
local globopts sedcmd modnames modopts
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-03-30 11:00 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-03-30 11:00 UTC (permalink / raw
To: gentoo-commits
commit: d9dc4a7b667e74e95ca4d9d655461be03a0e910e
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 30 10:58:17 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sun Mar 30 10:58:17 2014 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=d9dc4a7b
_eselect: update opengl options
---
_eselect | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_eselect b/_eselect
index ae105d5..1c1f6ec 100644
--- a/_eselect
+++ b/_eselect
@@ -89,7 +89,7 @@ _eselect_opengl () {
"--use-old[If an implementation is already set, use that one instead]" \
"--prefix[Set the source prefix]:path:_files -/" \
"--dst-prefix[Set the destination prefix]:path:_files -/" \
- "--impl-headers[Override global headers with ones provided by this profile]" && return 0
+ "--ignore-missing[Ignore missing files when setting a new implementation]" && return 0
fi
_values "opengl options" $common_values \
"list[List the available OpenGL implementations]" \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-25 11:26 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-25 11:26 UTC (permalink / raw
To: gentoo-commits
commit: 7134714bf6a778c13aa5b602a2b1f47c1ddbe008
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Mon Aug 25 11:24:50 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Mon Aug 25 11:24:50 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=7134714b
_openrc: rc-service support
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_openrc | 36 +++++++++++++++++++++++++++++++++++-
1 file changed, 35 insertions(+), 1 deletion(-)
diff --git a/_openrc b/_openrc
index fd3259d..10519f3 100644
--- a/_openrc
+++ b/_openrc
@@ -1,4 +1,4 @@
-#compdef rc-update rc-status rc
+#compdef rc-update rc-status rc rc-service
# openrc-0.12.4
@@ -6,6 +6,31 @@ local gentoo_runlevels
gentoo_runlevels=(/etc/runlevels/*(:t))
case "$service" in
+ rc-service)
+ if (( CURRENT == 2 )); then
+ _arguments -s \
+ '(-e --exists)'{-e,--exists}"[tests if the service exists or not]" \
+ '(-l --list)'{-l,--list}'[list all available services]' \
+ '(-r --resolve)'{-r,--resolve}'[resolve the service name to an init script]' \
+ '(-C --nocolor)'{-C,--nocolor}'[Disable color output]' \
+ '(-v --verbose)'{-v,--verbose}'[Run verbosely]' \
+ '(-q --quiet)'{-q,--quiet}'[Run quietly]'
+ _values "service" /etc/init.d/*~*.sh(:t)
+ else
+ case $words[2] in
+ -e|--exists|-r|--resolve)
+ (( CURRENT > 3 )) && return 0
+ _values "service" /etc/init.d/*~*.sh(:t)
+ ;;
+ -*)
+ return 0
+ ;;
+ *)
+ _values "action" stop start restart describe zap
+ ;;
+ esac
+ fi
+ ;;
rc-update)
local used_init
used_init=(${=${(M)${(f)"$(/sbin/rc-update show 2>/dev/null)"}:#*|*[a-z]*}% |*})
@@ -58,3 +83,12 @@ case "$service" in
fi
;;
esac
+
+
+# Local Variables:
+# mode: Shell-Script
+# sh-indentation: 2
+# indent-tabs-mode: nil
+# sh-basic-offset: 2
+# End:
+# vim: ft=zsh sw=2 ts=2 et
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-25 12:41 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-25 12:41 UTC (permalink / raw
To: gentoo-commits
commit: fd8e5c19b8ae8742886e62d9ec4609dacd97f4c0
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Mon Aug 25 12:35:30 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Mon Aug 25 12:38:03 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=fd8e5c19
_eselect: news support
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_eselect | 42 +++++++++++++++++++++++++++++++++++++++---
1 file changed, 39 insertions(+), 3 deletions(-)
diff --git a/_eselect b/_eselect
index 1c1f6ec..796a819 100644
--- a/_eselect
+++ b/_eselect
@@ -112,6 +112,42 @@ _eselect_vi () {
"update[Automatically update the vi provider]"
}
+_eselect_news() {
+
+ ## TODO: Normal numeric sorting.
+ ## I've spent many time on trying to rewrite this
+ ## function to normally sort (to DO NOT sort, actually) items,
+ ## but it growing bigger and bigger and going to be too complicated.
+ ## So, I (mva) either need to help to make it in the "right way".
+ ## Or, maybe, to completely rewrite this compdef.
+
+ local -a newslist;
+ if ((CURRENT == 3)); then
+ _values 'news options' $stdopts[@] \
+ 'list[List news items]' \
+ 'count[Display number of news items]' \
+ 'purge[Purge read news]' \
+ 'read[Read news items]' \
+ 'unread[Mark read news items as unread again]' && return 0
+ elif ((CURRENT == 4)); then
+ if (( $words[(I)(count)] )); then
+ _values -w 'news' 'new[Count only new news items]' 'all[Count all news items]' && return 0
+ fi
+
+ newslist=(${${${${${${${(M)${(f)"$(eselect --color=no news list)"}## *}// \**/}/ \[/}/\] ##/\[}/%/]}/ \[/ (}/\] /) })
+
+ if (( $words[(I)(read)] )); then
+ newslist+=( "new[Read unread news items (default)]" "all[Read all news items]" "--mbox[Output in mbox format]" "--quiet[Suppress output, only change status]" "--raw[Output in raw format]" )
+ fi;
+
+ if (( $words[(I)(unread)] )); then
+ newslist+=( "all[Unread all news items]" )
+ fi
+
+ _values -w 'news' $newslist[@] && return 0
+ fi
+}
+
_eselect () {
local globopts modnames modopts
@@ -131,7 +167,7 @@ _eselect () {
_arguments -s \
"*:portage:_values 'eselect modules' \$modnames[@]" && return 0
elif (( $modnames[(I)$words[2]] )); then
- if [[ "$words[2]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
+ if [[ "$words[2]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi|news) ]]; then
_eselect_$words[2] "$@"
else
modopts=(${${${(M)${(f)"$(eselect --brief --color=no $words[2] usage)"}## *}// */}// /})
@@ -142,7 +178,7 @@ _eselect () {
elif ((CURRENT >= 4)); then
if (( $words[(I)(--color=no|--colour=no)] )); then
if (( $modnames[(I)$words[3]] )); then
- if [[ "$words[3]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi) ]]; then
+ if [[ "$words[3]" == (env|binutils|kernel|ctags|profile|fontconfig|opengl|vi|news) ]]; then
_eselect_$words[3] "$@"
else
modopts=(${${${${(M)${(f)"$(eselect --brief --color=no $words[3] usage)"}## *}// */}// /}// *})
@@ -152,7 +188,7 @@ _eselect () {
fi
else
if (( $modnames[(I)$words[2]] )); then
- _eselect_$words[2] "$@"
+ (( $+functions[_eselect_$words[2]] )) && _eselect_$words[2] "$@"
fi
fi
fi
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-25 12:41 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-25 12:41 UTC (permalink / raw
To: gentoo-commits
commit: 604140682169d8871987575a338cd07b1f52b0e2
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Mon Aug 25 12:39:12 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Mon Aug 25 12:39:12 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=60414068
_openrc: remove vim/emacs formatting definitions
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_openrc | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/_openrc b/_openrc
index 10519f3..84ecbc8 100644
--- a/_openrc
+++ b/_openrc
@@ -83,12 +83,3 @@ case "$service" in
fi
;;
esac
-
-
-# Local Variables:
-# mode: Shell-Script
-# sh-indentation: 2
-# indent-tabs-mode: nil
-# sh-basic-offset: 2
-# End:
-# vim: ft=zsh sw=2 ts=2 et
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-25 16:13 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-25 16:13 UTC (permalink / raw
To: gentoo-commits
commit: 22f2f1fae54d9242b2e9a2fbc49918f1dbe6edbb
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Mon Aug 25 16:04:21 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Mon Aug 25 16:11:25 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=22f2f1fa
_eselect: news fix (typo in regexp)
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_eselect | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_eselect b/_eselect
index 796a819..c012955 100644
--- a/_eselect
+++ b/_eselect
@@ -134,7 +134,7 @@ _eselect_news() {
_values -w 'news' 'new[Count only new news items]' 'all[Count all news items]' && return 0
fi
- newslist=(${${${${${${${(M)${(f)"$(eselect --color=no news list)"}## *}// \**/}/ \[/}/\] ##/\[}/%/]}/ \[/ (}/\] /) })
+ newslist=(${${${${${${${(M)${(f)"$(eselect --color=no news list)"}## *}// \**/}/ \[/}/\] ##/\[}/%/]}/ \[/ (}/\] /) })
if (( $words[(I)(read)] )); then
newslist+=( "new[Read unread news items (default)]" "all[Read all news items]" "--mbox[Output in mbox format]" "--quiet[Suppress output, only change status]" "--raw[Output in raw format]" )
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-26 4:46 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-26 4:46 UTC (permalink / raw
To: gentoo-commits
commit: 9ccf71ce6ccd3dc3e9c1028da4d9b9247553a0e9
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Tue Aug 26 04:44:54 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Tue Aug 26 04:44:54 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=9ccf71ce
_gentoo_packages: repos.conf support
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_gentoo_packages | 237 +++++++++++++++++++++++++++++++++----------------------
_portage_utils | 91 +++++++++++++++++++--
2 files changed, 227 insertions(+), 101 deletions(-)
diff --git a/_gentoo_packages b/_gentoo_packages
index 767d592..f991cfb 100644
--- a/_gentoo_packages
+++ b/_gentoo_packages
@@ -5,58 +5,131 @@
# inspired by _deb_packages
#Usage: _gentoo_packages installed|available|installed_versions|available_versions|binary|category|useflag
+
+_portdir() {
+ local mainreponame mainrepopath overlayname overlaypath
+
+ if [[ -e /usr/share/portage/config/repos.conf ]]; then
+ if [[ ${1} == -o ]]; then
+ for overlayname in $(_parsereposconf -l); do
+ overlaypath+=($(_parsereposconf ${overlayname} location))
+ done
+
+ source /etc/make.conf 2>/dev/null
+ source /etc/portage/make.conf 2>/dev/null
+
+ overlaypath+=(${PORTDIR_OVERLAY})
+
+ # strip out duplicates
+ overlaypath=($(printf "%s\n" "${overlaypath[@]}" | sort -u))
+
+ echo "${overlaypath[@]}"
+ else
+ mainreponame=$(_parsereposconf DEFAULT main-repo)
+ mainrepopath=$(_parsereposconf ${mainreponame} location)
+
+ echo "${mainrepopath}"
+ fi
+ else
+ source /usr/share/portage/config/make.globals 2>/dev/null
+ source /etc/make.conf 2>/dev/null
+ source /etc/portage/make.conf 2>/dev/null
+
+ echo "${PORTDIR}"
+
+ if [[ ${1} == -o ]]; then⋅
+ echo "${PORTDIR_OVERLAY}"
+ fi⋅⋅⋅
+ fi
+}
+
+_parsereposconf() {
+ local f insection line section v value var
+
+ for f in /usr/share/portage/config/repos.conf \
+ /etc/portage/repos.conf \
+ /etc/portage/repos.conf/*.conf; do
+
+ [[ -f ${f} ]] || continue
+ insection=0
+
+ while read -r line; do
+ # skip comments and blank lines
+ [[ -z ${line} || ${line} == '#'* ]] && continue
+
+ if [[ ${insection} == 1 && ${line} == '['*']' ]]; then
+ # End of the section we were interested in so stop
+ secname+=(${line//[(\[|\])]/}) # record name for -l
+ break
+ elif [[ ${line} == '['*']' ]]; then
+ # Entering a new section, check if it's the one we want
+ section=${line//[(\[|\])]/}
+ [[ ${section} == "${1}" ]] && insection=1
+ secname+=(${section}) # record name for -l
+ elif [[ ${insection} == 1 ]]; then
+ # We're in the section we want, grab the values
+ var=${line%%=*}
+ var=${var// /}
+ value=${line#*=}
+ value=${value# }
+ [[ ${var} == ${2} ]] && v=${value}
+ fi
+ continue
+ done < "${f}"
+ done
+
+ if [[ ${1} == -l ]]; then
+ echo "${secname[@]}"
+ else
+ echo "${v}"
+ fi
+}
+
# Completion function to show useflags.
_gentoo_packages_update_useflag(){
- local flags PORTDIR
- var=PORTDIR
- [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
- local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
-
- flags=( ${${(M)${(f)"$(<$PORTDIR/profiles/use.desc)"}:#* - *}%% - *}
- ${${${(M)${(f)"$(<$PORTDIR/profiles/use.local.desc)"}#* - *}%% - *}#*:} )
+ local flags trees
+
+ flags=()
+ trees=( $(_portdir) $(_portdir -o) )
+
+ for PORTDIR in ${trees[@]}; do
+ [[ -r ${PORTDIR}/profiles/use.desc ]] &&
+ flags+=( ${${(M)${(f)"$(<$PORTDIR/profiles/use.desc)"}:#* - *}%% - *} )
+ [[ -r ${PORTDIR}/profiles/use.local.desc ]] &&
+ flags+=( ${${${(M)${(f)"$(<$PORTDIR/profiles/use.local.desc)"}#* - *}%% - *}#*:} )
+ done
+
compadd $flags
}
_gentoo_packages_update_active_useflag(){
- local flags USE
- var=USE
- [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- flags=(${${${=USE}%-*}%\\*})
- compadd $flags
+ local flags USE
+ var=USE
+ [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
+ local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
+ [[ -z ${(P)var} && -r /etc/make.conf ]] &&
+ local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
+ flags=(${${${=USE}%-*}%\\*})
+ compadd $flags
}
_gentoo_packages_update_category(){
- local var trees category
- for var in PORTDIR PORTDIR_OVERLAY ; do
- [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
- local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
- done
- trees=($PORTDIR $=PORTDIR_OVERLAY)
+ local trees category
+
+ trees=( $(_portdir) $(_portdir -o) )
category=( $trees/*-*(/:t) )
_wanted cat_packages expl 'category' compadd "$@" $category
}
_gentoo_packages_update_installed(){
- local installed_dir installed_portage installed_list expl
- installed_dir="/var/db/pkg"
- installed_portage=($installed_dir/*-*/*)
-
- installed_pkgname=( ${${installed_portage:t}%%-[0-9]*} )
- _wanted packages expl 'category/package' compadd "$@" ${installed_pkgname}
+ local installed_dir installed_portage installed_list expl
+ installed_dir="/var/db/pkg"
+ installed_portage=($installed_dir/*-*/*)
- installed_list=( ${${installed_portage#$installed_dir/}%%-[0-9]*} )
- _wanted cat_packages expl 'category/package' _multi_parts "$@" / installed_list
+ installed_pkgname=( ${${installed_portage:t}%%-[0-9]*} )
+ _wanted packages expl 'category/package' compadd "$@" ${installed_pkgname}
+ installed_list=( ${${installed_portage#$installed_dir/}%%-[0-9]*} )
+ _wanted cat_packages expl 'category/package' _multi_parts "$@" / installed_list
}
_gentoo_packages_update_installed_versions(){
@@ -70,34 +143,18 @@ _gentoo_packages_update_installed_versions(){
}
_gentoo_packages_update_available_pkgnames_only(){
- local var trees packages
-
- for var in PORTDIR PORTDIR_OVERLAY ; do
- [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
- local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
- done
- trees=( $PORTDIR $=PORTDIR_OVERLAY)
+ local trees packages
+
+ trees=( $(_portdir) $(_portdir -o) )
packages=( $trees/*-*/*(:t) )
_wanted packages expl 'package' compadd - "${(@)packages}"
}
_gentoo_packages_update_available(){
- local var trees category packages pkg expl
-
- for var in PORTDIR PORTDIR_OVERLAY ; do
- [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
- local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
- done
- trees=( $PORTDIR $=PORTDIR_OVERLAY)
+ local trees category packages pkg expl
+
+ trees=( $(_portdir) $(_portdir -o) )
category=( $trees/*-*(/:t) )
packages=( $trees/*-*/*(:t) )
@@ -108,33 +165,28 @@ _gentoo_packages_update_available(){
# complete cat/pkg/files (if "files" is ignored with -F, miscfiles, etc...
# don't get completed).
if [[ $PREFIX != */* ]] ; then
- _wanted cat_packages expl 'category/package' compadd -S '/' $category
+ _wanted cat_packages expl 'category/package' compadd -S '/' $category
else
- compset -P '*/'
- pkg=( $trees/$IPREFIX/*(:t) )
- _wanted cat_packages expl 'category/package' compadd $pkg
+ compset -P '*/'
+ pkg=( $trees/$IPREFIX/*(:t) )
+ _wanted cat_packages expl 'category/package' compadd $pkg
fi
}
_gentoo_packages_update_available_versions(){
local var overlay_ebuilds portage_ebuilds expl trees category
- for var in PORTDIR PORTDIR_OVERLAY ; do
- [[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
- [[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
- local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
- done
- trees=($PORTDIR $=PORTDIR_OVERLAY)
+ PORTDIR=$(_portdir)
+ PORTDIR_OVERLAY=$(_portdir -o);
+
+ trees=( $PORTDIR $=PORTDIR_OVERLAY )
category=( $trees/*-*(/:t) )
typeset -U category
if [[ $#PREFIX -ge 1 && -z $words[(r)(--inject|-i)] ]] ; then
- overlay_ebuilds=($=PORTDIR_OVERLAY/*-*/${PREFIX%%-[0-9]#*}*/*.ebuild(:t:r) )
- portage_ebuilds=($PORTDIR/metadata/cache/*-*/${PREFIX%%-[0-9]#*}*(:t))
- _wanted packages expl 'package' compadd $portage_ebuilds $overlay_ebuilds
+ overlay_ebuilds=($=PORTDIR_OVERLAY/*-*/${PREFIX%%-[0-9]#*}*/*.ebuild(:t:r) )
+ portage_ebuilds=($PORTDIR/metadata/cache/*-*/${PREFIX%%-[0-9]#*}*(:t))
+ _wanted packages expl 'package' compadd $portage_ebuilds $overlay_ebuilds
fi
pkg=( $trees/${PREFIX%%/*}/*/*.ebuild(:t:r) )
_wanted cat_packages expl 'category/package' _sep_parts category / pkg
@@ -143,11 +195,11 @@ _gentoo_packages_update_available_versions(){
#Function to show tbz2 files available
_gentoo_packages_update_binary() {
[[ -z $PKGDIR && -r /etc/portage/make.conf ]] &&
- local PKGDIR="`. /etc/portage/make.conf 2>/dev/null; echo $PKGDIR`"
+ local PKGDIR="`. /etc/portage/make.conf 2>/dev/null; echo $PKGDIR`"
[[ -z $PKGDIR && -r /etc/make.conf ]] &&
- local PKGDIR="`. /etc/make.conf 2>/dev/null; echo $PKGDIR`"
+ local PKGDIR="`. /etc/make.conf 2>/dev/null; echo $PKGDIR`"
[[ -z $PKGDIR && -r /usr/share/portage/config/make.globals ]] &&
- local PKGDIR="`. /usr/share/portage/config/make.globals 2>/dev/null; echo $PKGDIR`"
+ local PKGDIR="`. /usr/share/portage/config/make.globals 2>/dev/null; echo $PKGDIR`"
# this doesn't take care of ${PORTAGE_BINHOST}. If Gentoo official
# binary mirror will be available we should rewrite it accordingly.
@@ -155,21 +207,20 @@ _gentoo_packages_update_binary() {
}
_gentoo_packages () {
- local command="$argv[$#]" expl cachevar pkgset update_policy
- zstyle -s ":completion:*:*:$service:*" cache-policy update_policy
- if [[ -z "$update_policy" ]]; then
- zstyle ":completion:*:*:$service:*" cache-policy _gentoo_cache_policy
- fi
- [[ "$command" == (installed(_versions|)|available(_versions|)|binary|category|(active_|)useflag|available_pkgnames_only) ]] || {
- _message "unknown command: $command"
- return
- }
- [[ "$pkgset" == (installed(_versions|)|available(_versions|)|binary|category|(active_|)useflag|available_pkgnames_only) ]] || {
- pkgset="$command"
- }
- expl=("${(@)argv[1,-2]}")
- _gentoo_packages_update_$pkgset
-
+ local command="$argv[$#]" expl cachevar pkgset update_policy
+ zstyle -s ":completion:*:*:$service:*" cache-policy update_policy
+ if [[ -z "$update_policy" ]]; then
+ zstyle ":completion:*:*:$service:*" cache-policy _gentoo_cache_policy
+ fi
+ [[ "$command" == (installed(_versions|)|available(_versions|)|binary|category|(active_|)useflag|available_pkgnames_only) ]] || {
+ _message "unknown command: $command"
+ return
+ }
+ [[ "$pkgset" == (installed(_versions|)|available(_versions|)|binary|category|(active_|)useflag|available_pkgnames_only) ]] || {
+ pkgset="$command"
+ }
+ expl=("${(@)argv[1,-2]}")
+ _gentoo_packages_update_$pkgset
}
_gentoo_cache_policy () {
diff --git a/_portage_utils b/_portage_utils
index dc0d918..dbb45d6 100644
--- a/_portage_utils
+++ b/_portage_utils
@@ -2,15 +2,90 @@
# portage-utils-0.53
+
+_portdir() {
+ local mainreponame mainrepopath overlayname overlaypath
+
+ if [[ -e /usr/share/portage/config/repos.conf ]]; then
+ if [[ ${1} == -o ]]; then
+ for overlayname in $(_parsereposconf -l); do
+ overlaypath+=($(_parsereposconf ${overlayname} location))
+ done
+
+ source /etc/make.conf 2>/dev/null
+ source /etc/portage/make.conf 2>/dev/null
+
+ overlaypath+=(${PORTDIR_OVERLAY})
+
+ # strip out duplicates
+ overlaypath=($(printf "%s\n" "${overlaypath[@]}" | sort -u))
+
+ echo "${overlaypath[@]}"
+ else
+ mainreponame=$(_parsereposconf DEFAULT main-repo)
+ mainrepopath=$(_parsereposconf ${mainreponame} location)
+
+ echo "${mainrepopath}"
+ fi
+ else
+ source /usr/share/portage/config/make.globals 2>/dev/null
+ source /etc/make.conf 2>/dev/null
+ source /etc/portage/make.conf 2>/dev/null
+
+ echo "${PORTDIR}"
+
+ if [[ ${1} == -o ]]; then⋅
+ echo "${PORTDIR_OVERLAY}"
+ fi⋅⋅⋅
+ fi
+}
+
+_parsereposconf() {
+ local f insection line section v value var
+
+ for f in /usr/share/portage/config/repos.conf \
+ /etc/portage/repos.conf \
+ /etc/portage/repos.conf/*.conf; do
+
+ [[ -f ${f} ]] || continue
+ insection=0
+
+ while read -r line; do
+ # skip comments and blank lines
+ [[ -z ${line} || ${line} == '#'* ]] && continue
+
+ if [[ ${insection} == 1 && ${line} == '['*']' ]]; then
+ # End of the section we were interested in so stop
+ secname+=(${line//[(\[|\])]/}) # record name for -l
+ break
+ elif [[ ${line} == '['*']' ]]; then
+ # Entering a new section, check if it's the one we want
+ section=${line//[(\[|\])]/}
+ [[ ${section} == "${1}" ]] && insection=1
+ secname+=(${section}) # record name for -l
+ elif [[ ${insection} == 1 ]]; then
+ # We're in the section we want, grab the values
+ var=${line%%=*}
+ var=${var// /}
+ value=${line#*=}
+ value=${value# }
+ [[ ${var} == ${2} ]] && v=${value}
+ fi
+ continue
+ done < "${f}"
+ done
+
+ if [[ ${1} == -l ]]; then
+ echo "${secname[@]}"
+ else
+ echo "${v}"
+ fi
+}
+
+
local common_args PORTDIR
-var=PORTDIR
-
-[[ -z ${(P)var} && -r /etc/portage/make.conf ]] &&
- local $var="`. /etc/portage/make.conf 2>/dev/null; echo ${(P)var}`"
-[[ -z ${(P)var} && -r /etc/make.conf ]] &&
- local $var="`. /etc/make.conf 2>/dev/null; echo ${(P)var}`"
-[[ -z ${(P)var} && -r /usr/share/portage/config/make.globals ]] &&
- local $var="`. /usr/share/portage/config/make.globals 2>/dev/null; echo ${(P)var}`"
+
+PORTDIR="$(_portdir)"
common_args=(
'--root[Set the ROOT env var]:root directory:_files -/' \
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-26 18:51 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-26 18:51 UTC (permalink / raw
To: gentoo-commits
commit: e63d605954915b2fdefe5a5353759359263c2a28
Author: Michael Cook (mackal) <mcook <AT> mackal <DOT> net>
AuthorDate: Tue Aug 26 18:36:10 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Tue Aug 26 18:49:05 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=e63d6059
Add more equery options
---
_gentoolkit | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/_gentoolkit b/_gentoolkit
index 2a87bd7..ef3db9a 100644
--- a/_gentoolkit
+++ b/_gentoolkit
@@ -126,6 +126,18 @@ _equery () {
'--filter=[filter output]:filter(s):_values -s , '' dir obj sym dev fifo path conf cmd doc man info' \
':installed pkgname:_packages installed' && ret=0
;;
+ meta|m)
+ _arguments \
+ '(-d --description)'{-d,--description}'[show an extended package description]' \
+ '(-H --herd)'{-H,--herd}'[show the herd(s) for the package]' \
+ '(-k --keywords)'{-k,--keywords}'[show keywords for all matching package versions]' \
+ '(-m --maintainer)'{-m,--maintainer}'[show the maintainer(s) for the package]' \
+ '(-S --stablreq)'{-S,--stablreq}'[show STABLEREQ arches (ccs) for all matching package versions]' \
+ '(-u --useflags)'{-u,--useflags}'[show per-package USE flag descriptions]' \
+ '(-U --upstream)'{-U,--upstream}'[show packages upstream information]' \
+ '(-x --xml)'{-x,--xml}'[show the plain metadata.xml file]' \
+ ':package:_packages available' && ret=0
+ ;;
hasuse|h)
_arguments \
$common_args \
@@ -150,6 +162,12 @@ _equery () {
{--all,-a}'[include non-installed packages]' \
":portage:_packages installed" && ret=0
;;
+ changes|c)
+ _arguments \
+ '(-l --latest)'{-l,--latest}'[only display latest ChangeLog entry]' \
+ '(-f --full)'{-f,--full}'[display full ChangeLog entry]' \
+ ':portage:_packages available' && ret=0
+ ;;
*)
_message 'command not found'
;;
@@ -160,6 +178,7 @@ _equery () {
tmp=(
{belongs,b}'[list all packages owning file(s)]'
{check,k}'[check MD5sums and timestamps of package]'
+ {changes,c}'[shows ChangeLog for specified package]'
{depends,d}'[list all packages depending on specified package]'
{depgraph,g}'[display a dependency tree for package]'
{files,f}'[list files owned by package]'
@@ -168,6 +187,9 @@ _equery () {
{size,s}'[print size of files contained in package]'
{uses,u}'[display USE flags for package]'
{which,w}'[print full path to ebuild for package]'
+ {has,a}'[list all packages matching ENVIRONMENT data stored in /var/db/pkg]'
+ {keywords,y}'[display keywords for specified PKG]'
+ {meta,m}'[display metadata about PKG]'
)
_values 'equery command' $tmp && ret=0
;;
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-30 10:19 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-30 10:19 UTC (permalink / raw
To: gentoo-commits
commit: 518f11eedce64dc3aa0e494c50755b886ca44a40
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Sat Aug 30 10:17:27 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Sat Aug 30 10:17:27 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=518f11ee
_gentoo_packages, _portage: reworked sets completion, added portage options
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_gentoo_packages | 38 +++++++++++--------------
_portage | 86 ++++++++++++++++++++++++++++++++++++++++++++++----------
2 files changed, 87 insertions(+), 37 deletions(-)
diff --git a/_gentoo_packages b/_gentoo_packages
index e770181..9a747b7 100644
--- a/_gentoo_packages
+++ b/_gentoo_packages
@@ -133,15 +133,15 @@ _parsesetsconf() {
fi
}
-_get_installed_sets() {
+_gentoo_packages_update_installed_sets() {
local sets;
sets=($(</var/lib/portage/world_sets));
if [[ ((${#sets} > 0)) ]]; then
- echo "${(o@)^sets}"
+ _wanted installed_sets expl 'installed set' compadd "$@" "${(o@)^sets}"
fi
}
-_get_available_sets() {
+_gentoo_packages_update_available_sets() {
trees=($(_portdir -o) /etc/portage /usr/share/portage/config)
for PORTDIR in ${(@)trees}; do
if [[ -d ${PORTDIR} ]]; then
@@ -157,7 +157,7 @@ _get_available_sets() {
fi
done
if [[ ((${#sets} > 0)) ]]; then
- echo "@${(o@)^sets}"
+ _wanted available_sets expl 'available set' compadd "$@" "@${(o@)^sets}"
fi
}
@@ -201,9 +201,6 @@ _gentoo_packages_update_installed(){
installed_dir="/var/db/pkg"
installed_portage=($installed_dir/*-*/*)
- installed_sets=($(_get_installed_sets))
- _wanted installed_sets expl 'installed set' compadd "$@" "${(o@)^installed_sets}"
-
installed_pkgname=(${${installed_portage:t}%%-[0-9]*})
_wanted packages expl 'package' compadd "$@" ${installed_pkgname}
@@ -224,22 +221,19 @@ _gentoo_packages_update_installed_versions(){
_gentoo_packages_update_available_pkgnames_only(){
local trees packages
- trees=( $(_portdir) $(_portdir -o) )
+ trees=($(_portdir) $(_portdir -o))
- packages=( $trees/*-*/*(:t) )
+ packages=($trees/*-*/*(:t))
_wanted packages expl 'package' compadd - "${(@)packages}"
}
_gentoo_packages_update_available(){
local trees category packages pkg expl
- trees=( $(_portdir) $(_portdir -o) )
- category=( $trees/*-*(/:t) )
-
- available_sets=( $(_get_available_sets) )
- _wanted available_sets expl 'available sets' compadd "${@}" "${(@)available_sets}"
+ trees=($(_portdir) $(_portdir -o))
+ category=($trees/*-*(/:t))
- packages=( $trees/*-*/*(:t) )
+ packages=($trees/*-*/*(:t))
_wanted packages expl 'package' compadd - "${(@)packages}"
# Complete cat/pkg. _multi_parts is much to slow for such a large task,
@@ -250,7 +244,7 @@ _gentoo_packages_update_available(){
_wanted cat_packages expl 'category/package' compadd -S '/' $category
else
compset -P '*/'
- pkg=( $trees/$IPREFIX/*(:t) )
+ pkg=($trees/$IPREFIX/*(:t))
_wanted cat_packages expl 'category/package' compadd $pkg
fi
}
@@ -261,14 +255,14 @@ _gentoo_packages_update_available_versions(){
PORTDIR=$(_portdir)
PORTDIR_OVERLAY=$(_portdir -o);
- trees=( $PORTDIR $=PORTDIR_OVERLAY )
- category=( $trees/*-*(/:t) )
+ trees=($PORTDIR $=PORTDIR_OVERLAY)
+ category=($trees/*-*(/:t))
typeset -U category
- if [[ $#PREFIX -ge 1 && -z $words[(r)(--inject|-i)] ]] ; then
+ if [[ $#PREFIX -ge 1 && -z $words[(r)(--inject|-i)] ]] ; then
overlay_ebuilds=($=PORTDIR_OVERLAY/*-*/${PREFIX%%-[0-9]#*}*/*.ebuild(:t:r) )
portage_ebuilds=($PORTDIR/metadata/cache/*-*/${PREFIX%%-[0-9]#*}*(:t))
- _wanted packages expl 'package' compadd $portage_ebuilds $overlay_ebuilds
+ _wanted packages expl 'package' compadd $portage_ebuilds $overlay_ebuilds
fi
pkg=( $trees/${PREFIX%%/*}/*/*.ebuild(:t:r) )
_wanted cat_packages expl 'category/package' _sep_parts category / pkg
@@ -294,11 +288,11 @@ _gentoo_packages () {
if [[ -z "$update_policy" ]]; then
zstyle ":completion:*:*:$service:*" cache-policy _gentoo_cache_policy
fi
- [[ "$command" == (installed(_versions|)|available(_versions|)|binary|category|(active_|)useflag|available_pkgnames_only) ]] || {
+ [[ "$command" == (installed(_versions|_sets|)|available(_versions|_sets|_pkgnames_only|)|binary|category|(active_|)useflag) ]] || {
_message "unknown command: $command"
return
}
- [[ "$pkgset" == (installed(_versions|)|available(_versions|)|binary|category|(active_|)useflag|available_pkgnames_only) ]] || {
+ [[ "$pkgset" == (installed(_versions|_sets|)|available(_versions|_sets|_pkgnames_only|)|binary|category|(active_|)useflag) ]] || {
pkgset="$command"
}
expl=("${(@)argv[1,-2]}")
diff --git a/_portage b/_portage
index e241357..57fc0a5 100644
--- a/_portage
+++ b/_portage
@@ -60,21 +60,21 @@ _quickpkg () {
# Stuff for emerge
_emerge () {
- local nopkg_opts all noask_opts bopts install_args common_args profiles
+ local nopkg_opts all noask_opts bopts install_args common_args profiles
noask_opts=(-p -a --pretend --ask --regen --info --search -s --searchdesc \
- -S --version -V --help -h --metadata)
+ -S --version -V --help -h --metadata --check-news)
nopkg_opts=(--resume --skipfirst -c --clean -h --help --depclean --info \
--metadata -P --prune --regen -s --search -S --searchdesc --sync -C \
- --unmerge -V --version -i --inject)
+ --unmerge -V --version -i --inject --list-sets --deselect --check-news)
bopts=($nopkg_opts -b --buildpkg -B --buildpkgonly -G --getbinpkgonly -g \
--getbinpkg -k --usepkg -K --usepkgonly --fetch-all-uri -f -F --fetchonly)
all=($bopts -l --changelog --columns --deep -D --emptytree -e --newuse \
--noconfmem --nodeps -O --noreplace -n --oneshot -1 -o --onlydeps --tree -t \
- -u --update -U --upgradeonly)
+ -u --update -U --upgradeonly --config)
common_args=(
"($noask_opts --sync)"{-p,--pretend}"[Simply display what would be done]"
@@ -83,15 +83,73 @@ _emerge () {
'(--quiet -q --verbose -v)'{-q,--quiet}'[General outcome is a reduced or condensed output]'
'(--verbose -v --quiet -q)'{-v,--verbose}'[Tell emerge to run in verbose mode]'
'--nospinner[Disables the spinner for the session]'
- #'--deselect[--deselect=n Remove atom from world file]'
- '--deselect=[Remove atom from world file]'
+ '(: -)'{-h,--help}'[Displays help]'
+ "(: -)--config[Run package specific actions needed to be executed after the emerge process has completed]:installed atom:_gentoo_packages installed"
+ "(: -)--list-sets[Displays a list of available package sets]"
+ "--color=[Color output]:yes/no:((y\:'yes' n\:'no'))"
+ "--accept-properties=[Temporarily override the ACCEPT_PROPERTIES variable]"
+ "--accept-restrict=[Temporarily override the ACCEPT_RESTRICT variable]"
+ "($noask_opts)"{-A,--alert=}"[Add a terminal bell to all interactive prompts]:yes/no:((y\:'yes' n\:'no'))"
+ "--ignore-default-opts[Ignore EMERGE_DEFAULT_OPTS]"
+ "--moo[Have you mooed today?]"
)
install_args=(
- "($bopts)"{-b,--buildpkg}"[Tells emerge to build binary packages]"
+ '--deselect=[Remove atom from world file]:yes/no:((y\:'yes' n\:'no'))'
+ "--alphabetical[Sort use/other flags output alphabetically despite of status]"
+ "--ask-enter-invalid[When with --ask, interpret a single 'Enter' key press as invalid input]"
+ "--autounmask[Automatically unmask packages and generate package.use]:yes/no:((y\:'yes' n\:'no'))"
+ "--autounmask-unrestricted-atoms[Use >= for autounmask if possible]:yes/no:((y\:'yes' n\:'no'))"
+ "--autounmask-keep-masks[Don't unmask hardmasks and unkeyworded (live)]:yes/no:((y\:'yes' n\:'no'))"
+ "--autounmask-write[Automatically write autounmask changes (respect CONFIG_PROTECT)]:yes/no:((y\:'yes' n\:'no'))"
+ "--backtrack=[Number of times to backtrack if dependency calculation fails]:number:(0 10 30)"
+ "--binpkg-respect-use=[Ignore binary packages if their uses don't match current config]:yes/no:((y\:'yes' n\:'no'))"
+ "--complete-graph=[Consider the deep dependencies of all packages from the world set]:yes/no:((y\:'yes' n\:'no'))"
+ "--complete-graph-if-new-use=[--complete-graph if USE or IUSE will change for an installed package]:yes/no:((y\:'yes' n\:'no'))"
+ "--complete-graph-if-new-ver=[--complete-graph if an installed package version will change]:yes/no:((y\:'yes' n\:'no'))"
+ "--config-root=[Set PORTAGE_CONFIGROOT variable]:root path:_files -/"
+ "--depclean-lib-check=[Check library link-level dependencies]:yes/no:((y\:'yes' n\:'no'))"
+ "--digest[Prevent corruption from being noticed]"
+ "--dynamic-deps=[Substitute the dependencies of installed packages with the dependencies of corresponding unbuilt ebuilds]:yes/no:((y\:'yes' n\:'no'))"
+ "--fail-clean=[Clean up temporary files after a build failure]:yes/no:((y\:'yes' n\:'no'))"
+ "--ignore-built-slot-operator-deps=[Ignore the slot/sub-slot dependencies for built pkg]:yes/no:((y\:'yes' n\:'no'))"
+ "(: $nopkg_opts)"{-j,--jobs=}"[Number of packages to build simultaneously]:jobs:({1.."${#${$(</proc/cpuinfo)/^processor}}"})"
+ "--keep-going[Continue as much as possible after an error]:yes/no:((y\:'yes' n\:'no'))"
+ "--load-average[No new builds should be started if there are other builds running and the load average is at least VALUE]"
+ "--misspell-suggestions[Enable or disable misspell suggestions]:yes/no:((y\:'yes' n\:'no'))"
+ "--newrepo[Recompile a package if it is now being pulled from a different repository]"
+ "--usepkg-exclude[Ignore matching binary packages]:installed atom:_gentoo_packages installed"
+ "--rebuild-exclude[Do not rebuild matching packages on --rebuild]:installed atom:_gentoo_packages installed"
+ "--rebuild-ignore[Do not rebuild packages that depend on matching packages on --rebuild]:installed atom:_gentoo_packages installed"
+ "--package-moves[Perform package moves when necessary]:yes/no:((y\:'yes' n\:'no'))"
+ "--pkg-format[Binary package format]:archive type:(tar rpm)"
+ "--prefix=[Set EPREFIX env variable]:prefix path:_files -/"
+ "--quiet-build=[Redirect all build output to logs]:yes/no:((y\:'yes' n\:'no'))"
+ "--quiet-fail=[Suppresses display of the build log on stdout]:yes/no:((y\:'yes' n\:'no'))"
+ "--quiet-repo-display[Suppress ::repository in output (and use numbers)]"
+ "--quiet-unmerge-warn[Disable the warning message on --unmerge and friends]"
+ "--rebuild-if-new-slot[Automatically rebuild or reinstall packages when dependencies can be satisfied by a newer slot]:yes/no:((y\:'yes' n\:'no'))"
+ "--rebuild-if-new-rev[Rebuild packages when build-time dependencies are built from source, if the dependency is not already installed with the same version and revision]:yes/no:((y\:'yes' n\:'no'))"
+ "--rebuild-if-new-ver[Rebuild packages when build-time dependencies are built from source, if the dependency is not already installed with the same version]:yes/no:((y\:'yes' n\:'no'))"
+ "--rebuild-if-unbuilt[Rebuild packages when build-time dependencies are built from source]:yes/no:((y\:'yes' n\:'no'))"
+ "--rebuilt-binaries[Replace installed packages with binary packages that have been rebuilt]:yes/no:((y\:'yes' n\:'no'))"
+ "--rebuilt-binaries-timestamp[Only binaries older than TIMESTAMP will be considered by the rebuilt-binaries logic]:TIMESTAMP"
+ "--reinstall[Alias for --changed-use (currently)]:reinstall opts:(changes-use)"
+ "--reinstall-atoms[Treat matching packages as if they are not installed]:installed atoms:_gentoo_packages installed"
+ "--root=[Set ROOT env variable]:prefix path:_files -/"
+ "(: $nopkg_opts)"{-w,--select=}"[Add specified packages to the world set (inverse of --oneshot)]:yes/no:((y\:'yes' n\:'no'))"
+ "--selective=[Use --selective=n if you want to forcefully disable --selective, regardless of options like --changed-use, --newuse, --noreplace, or --update]:yes/no:((y\:'yes' n\:'no'))"
+ "--unordered-display[Produce more readable package tree with --tree]"
+ "--use-ebuild-visibility[Use unbuilt ebuild metadata for visibility checks on built packages]:yes/no:((y\:'yes' n\:'no'))"
+ "--useoldpkg-atoms[Prefer matching binary packages over newer unbuilt packages]:available atom:_gentoo_packages available"
+ "($bopts)"{-b,--buildpkg=}"[Tells emerge to build binary packages]:(y n)"
+ "($bopts)--buildpkg-exclude[Space separated list of package atoms for which no binary packages should be built]"
+ "($bopts)--exclude[Space separated list of package names or slot atoms which should not be installed]"
"($bopts)"{-B,--buildpkgonly}"[Tells emerge to only build binary packages]"
"($nopkg_opts --emptytree -e -l --changelog --usepkgonly -K)"{-l,--changelog}"[This will show the ChangeLog]"
"($nopkg_opts -t --tree)--columns[Displays versions in aligned format]"
- "($nopkg_opts -D --deep)"{-D,--deep}"[Consider the entire dependency tree of packages]"
+ "($nopkg_opts -D --deep --newuse -N --changed-use)"{-D,--deep}"[Consider the entire dependency tree of packages]"
+ "($nopkg_opts -D --deep --newuse -N --changed-use)"{-N,--newuse}"[Include installed packages where any USE flags have changed since compilation.]"
+ "($nopkg_opts -D --deep --newuse -N --changed-use)--changed-use[Include installed packages where enabled USE flags have changed since installation]"
"($nopkg_opts -e -l --changelog --emptytree)"{-e,--emptytree}"[Only consider glibc as installed packages]"
"($all --nospinner --pretend -p)"{-i,--inject}"[Portage thinks that this package is installed]"
"($nopkg_opts $bopts)"{-f,--fetchonly}"[Just perform fetches for all packages]"
@@ -108,9 +166,8 @@ _emerge () {
"($nopkg_opts --upgradeonly -U)"{-U,--upgradeonly}"[Do not update packages to a lower version]"
"($bopts)"{-k,--usepkg}"[Tells emerge to use binary packages if available]"
"($bopts --changelog -l)"{-K,--usepkgonly}"[Tells emerge to use binary packages only]"
- "($all)"{-c,--clean}"[Cleans the system by removing packages]"
- '(: -)'{-h,--help}'[Displays help]:subject:(sync config system)'
- "(: $all)--depclean[Clean all packages that have no reason for being installed]"
+ "($all)--clean[Cleans the system by removing packages]"
+ "(: $all)"{-c,--depclean}"[Clean all packages that have no reason for being installed (see man!!!)]"
"(: $all $noask_opts --nospinner --quiet -q)--info[This is a list of information to include in bug reports]"
"(: -)--metadata[Generate metadata]"
"($nopkg_opts --usepkgonly -K)--newuse[Include installed packages which have changed USE flags]"
@@ -119,6 +176,7 @@ _emerge () {
"(: $all $noask_opts --verbose -v)"{-s,--search}"[Searches for matches]"
"(: $all $noask_opts --verbose -v)"{-S,--searchdesc}"[Matches the seachdesc string against the description field]"
"(: $all --pretend -p)--sync[Initiates a portage tree update]"
+ "(: $all --pretend -p)--check-news[Scan all repositories for relevant unread GLEP 42 news items]"
"($all)"{-C,--unmerge}"[Removes all matching packages]"
'(: -)'{-V,--version}'[Display version info]'
"(: $all[3,-1])--resume[Resumes the last merge operation]"
@@ -139,6 +197,7 @@ _emerge () {
_arguments -s \
"$common_args[@]" "$install_args[@]" \
"*:installed package:_gentoo_packages installed" \
+ "::installed sets:_gentoo_packages installed_sets" \
&& return 0
fi
@@ -152,14 +211,10 @@ _emerge () {
"$common_args[@]" "$install_args[@]" \
'*:binary package:_gentoo_packages binary' && return 0
- elif [[ $words[-3] == (--help|-h) ]] ; then
- _message "No more arguments" && return 0
-
else
if compset -P '(\\|)(>=|<=|<|>|=)'; then
_arguments \
"*:portage:_gentoo_packages available_versions" && return 0
-
elif (( $words[(I)(--inject|-i)] )) ; then
_arguments -s \
"$common_args[@]" "$install_args[@]" \
@@ -169,6 +224,7 @@ _emerge () {
"$common_args[@]" "$install_args[@]" \
"($nopkg_opts)::portage: _values 'profile' \$profiles[@] " \
"($nopkg_opts)*:portage:_gentoo_packages available" \
+ "($nopkg_opts)::available sets:_gentoo_packages available_sets" \
&& return 0
fi
fi
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-08-30 10:19 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-08-30 10:19 UTC (permalink / raw
To: gentoo-commits
commit: 99c322fb13deffac2f1ee9bebbfd43d3eaf08b33
Author: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
AuthorDate: Fri Aug 29 18:45:26 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Fri Aug 29 18:45:26 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=99c322fb
_gentoo_packages, _portage: Added sets completion
Signed-off-by: Vadim A. Misbakh-Soloviov <mva <AT> mva.name>
---
_gentoo_packages | 160 +++++++++++++++++++++++++++++++++++++++++--------------
_portage | 6 ++-
2 files changed, 125 insertions(+), 41 deletions(-)
diff --git a/_gentoo_packages b/_gentoo_packages
index f991cfb..e770181 100644
--- a/_gentoo_packages
+++ b/_gentoo_packages
@@ -1,5 +1,6 @@
#autoload
+setopt extendedglob bareglobqual
#Description:
# functions for gentoo packages
# inspired by _deb_packages
@@ -18,12 +19,9 @@ _portdir() {
source /etc/make.conf 2>/dev/null
source /etc/portage/make.conf 2>/dev/null
- overlaypath+=(${PORTDIR_OVERLAY})
+ overlaypath+=(${(@)PORTDIR_OVERLAY})
- # strip out duplicates
- overlaypath=($(printf "%s\n" "${overlaypath[@]}" | sort -u))
-
- echo "${overlaypath[@]}"
+ echo "${(@u)overlaypath}"
else
mainreponame=$(_parsereposconf DEFAULT main-repo)
mainrepopath=$(_parsereposconf ${mainreponame} location)
@@ -35,68 +33,146 @@ _portdir() {
source /etc/make.conf 2>/dev/null
source /etc/portage/make.conf 2>/dev/null
- echo "${PORTDIR}"
-
- if [[ ${1} == -o ]]; then⋅
- echo "${PORTDIR_OVERLAY}"
- fi⋅⋅⋅
+ if [[ "-o" == ${1} ]]; then
+ echo "${(@u)PORTDIR_OVERLAY}"
+ else
+ echo "${PORTDIR}"
+ fi
fi
}
_parsereposconf() {
- local f insection line section v value var
+ local v f insection section arr;
for f in /usr/share/portage/config/repos.conf \
/etc/portage/repos.conf \
/etc/portage/repos.conf/*.conf; do
[[ -f ${f} ]] || continue
- insection=0
+ insection=0;
+ declare -A arr;
+ IFS='= ';
- while read -r line; do
- # skip comments and blank lines
- [[ -z ${line} || ${line} == '#'* ]] && continue
+ while read -r name value; do
+ [[ -z ${name} || ${name} == '#'* ]] && continue
- if [[ ${insection} == 1 && ${line} == '['*']' ]]; then
- # End of the section we were interested in so stop
- secname+=(${line//[(\[|\])]/}) # record name for -l
+ if [[ (${name} == '['*']') && (-z ${value}) ]]; then
+ value=${name//(\]|\[)};
+ name="section";
+ fi;
+ arr[${name}]=${value};
+
+ if [[ ${insection} == 1 && ${name} == "section" ]]; then
break
- elif [[ ${line} == '['*']' ]]; then
- # Entering a new section, check if it's the one we want
- section=${line//[(\[|\])]/}
- [[ ${section} == "${1}" ]] && insection=1
- secname+=(${section}) # record name for -l
+ elif [[ ${name} == "section" ]]; then
+ [[ ${value} == ${1} ]] && insection=1
+ secname+=(${value})
elif [[ ${insection} == 1 ]]; then
- # We're in the section we want, grab the values
- var=${line%%=*}
- var=${var// /}
- value=${line#*=}
- value=${value# }
- [[ ${var} == ${2} ]] && v=${value}
+ if [[ ${name} == ${2} ]]; then
+ v=${value};
+ fi
fi
continue
- done < "${f}"
+ done < ${f}
done
- if [[ ${1} == -l ]]; then
- echo "${secname[@]}"
+ if [[ "-l" == ${1} ]]; then
+ echo "${(@)secname}"
else
echo "${v}"
fi
}
+_parsesetsconf() {
+ [[ -d ${1} ]] || continue
+
+ local v f places sections setsconf insection section arr;
+
+ if [[ -d ${1}/sets ]]; then
+ setsconf=(${1}/sets/*.conf(N));
+ [[ (($#setsconf > 0)) ]] && places=(${setsconf})
+ elif [[ -f ${1}/sets.conf ]]; then
+ places=(${1}/sets.conf)
+ fi
+
+ for f in ${(@)places}; do
+ if [[ -r ${f} ]]; then
+ insection=0;
+ declare -A arr;
+ IFS='= ';
+ while read -r name value; do
+ [[ -z ${name} || ${name} == '#'* ]] && continue
+
+ if [[ (${name} == '['*']') && (-z ${value}) ]]; then
+ value=${name//(\]|\[)};
+ name="section";
+ fi;
+ arr[${name}]=${value};
+
+ if [[ ${insection} == 1 && ${name} == "section" ]]; then
+ [[ "sets" == ${2} ]] && [[ ! ${value} =~ "sets" ]] && sections+=(${value})
+ insection=0;
+ elif [[ ${name} == "section" ]]; then
+ [[ ${value} =~ "${1:t} sets" ]] && insection=1
+ [[ "sets" == ${2} ]] && [[ ! ${value} =~ "sets" ]] && sections+=(${value})
+ elif [[ ${insection} == 1 ]]; then
+ [[ "sets" == ${2} ]] && continue
+ if [[ ${name} == "directory" ]]; then
+ v=${value};
+ fi
+ fi
+ continue
+ done < ${f}
+ fi
+ done
+
+ if [[ "sets" == ${2} ]]; then
+ [[ ((${#sections} > 0)) ]] && echo ${(@)sections}
+ else
+ [[ ((${#v} > 0)) ]] && echo ${v:t};
+ fi
+}
+
+_get_installed_sets() {
+ local sets;
+ sets=($(</var/lib/portage/world_sets));
+ if [[ ((${#sets} > 0)) ]]; then
+ echo "${(o@)^sets}"
+ fi
+}
+
+_get_available_sets() {
+ trees=($(_portdir -o) /etc/portage /usr/share/portage/config)
+ for PORTDIR in ${(@)trees}; do
+ if [[ -d ${PORTDIR} ]]; then
+ setsdir="$(_parsesetsconf ${PORTDIR})"
+ [[ ! -z "${setsdir}" ]] && setspath="${PORTDIR}/${setsdir}" || setspath="${PORTDIR}/sets"
+ if [[ -d "${setspath}" ]]; then
+ setsfiles=(${setspath}/*~*.conf(N))
+ for set in ${setsfiles[@]}; do
+ sets+=(${set}(:t))
+ done;
+ sets+=($(_parsesetsconf ${PORTDIR} sets))
+ fi
+ fi
+ done
+ if [[ ((${#sets} > 0)) ]]; then
+ echo "@${(o@)^sets}"
+ fi
+}
+
# Completion function to show useflags.
_gentoo_packages_update_useflag(){
local flags trees
flags=()
- trees=( $(_portdir) $(_portdir -o) )
+ trees=($(_portdir) $(_portdir -o))
for PORTDIR in ${trees[@]}; do
[[ -r ${PORTDIR}/profiles/use.desc ]] &&
- flags+=( ${${(M)${(f)"$(<$PORTDIR/profiles/use.desc)"}:#* - *}%% - *} )
+ flags+=(${${(M)${(f)"$(<$PORTDIR/profiles/use.desc)"}:#* - *}%% - *})
[[ -r ${PORTDIR}/profiles/use.local.desc ]] &&
- flags+=( ${${${(M)${(f)"$(<$PORTDIR/profiles/use.local.desc)"}#* - *}%% - *}#*:} )
+ flags+=(${${${(M)${(f)"$(<$PORTDIR/profiles/use.local.desc)"}#* - *}%% - *}#*:})
done
compadd $flags
@@ -115,7 +191,7 @@ _gentoo_packages_update_active_useflag(){
_gentoo_packages_update_category(){
local trees category
- trees=( $(_portdir) $(_portdir -o) )
+ trees=($(_portdir) $(_portdir -o))
category=( $trees/*-*(/:t) )
_wanted cat_packages expl 'category' compadd "$@" $category
}
@@ -125,8 +201,11 @@ _gentoo_packages_update_installed(){
installed_dir="/var/db/pkg"
installed_portage=($installed_dir/*-*/*)
- installed_pkgname=( ${${installed_portage:t}%%-[0-9]*} )
- _wanted packages expl 'category/package' compadd "$@" ${installed_pkgname}
+ installed_sets=($(_get_installed_sets))
+ _wanted installed_sets expl 'installed set' compadd "$@" "${(o@)^installed_sets}"
+
+ installed_pkgname=(${${installed_portage:t}%%-[0-9]*})
+ _wanted packages expl 'package' compadd "$@" ${installed_pkgname}
installed_list=( ${${installed_portage#$installed_dir/}%%-[0-9]*} )
_wanted cat_packages expl 'category/package' _multi_parts "$@" / installed_list
@@ -138,7 +217,7 @@ _gentoo_packages_update_installed_versions(){
installed_portage=(/var/db/pkg/*-*/*)
_wanted packages expl 'package' compadd "$@" ${installed_portage:t}
- installed_list=( ${installed_portage##*/pkg/} )
+ installed_list=(${installed_portage##*/pkg/})
_wanted cat_packages expl 'category/package' _multi_parts "$@" / installed_list
}
@@ -157,6 +236,9 @@ _gentoo_packages_update_available(){
trees=( $(_portdir) $(_portdir -o) )
category=( $trees/*-*(/:t) )
+ available_sets=( $(_get_available_sets) )
+ _wanted available_sets expl 'available sets' compadd "${@}" "${(@)available_sets}"
+
packages=( $trees/*-*/*(:t) )
_wanted packages expl 'package' compadd - "${(@)packages}"
diff --git a/_portage b/_portage
index ee7b2ab..e241357 100644
--- a/_portage
+++ b/_portage
@@ -138,7 +138,8 @@ _emerge () {
else
_arguments -s \
"$common_args[@]" "$install_args[@]" \
- "*:installed package:_gentoo_packages installed" && return 0
+ "*:installed package:_gentoo_packages installed" \
+ && return 0
fi
elif (( $words[(I)(world|system)] )) ; then
@@ -167,7 +168,8 @@ _emerge () {
_arguments -s \
"$common_args[@]" "$install_args[@]" \
"($nopkg_opts)::portage: _values 'profile' \$profiles[@] " \
- "($nopkg_opts)*:portage:_gentoo_packages available" && return 0
+ "($nopkg_opts)*:portage:_gentoo_packages available" \
+ && return 0
fi
fi
}
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-11-15 8:40 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-11-15 8:40 UTC (permalink / raw
To: gentoo-commits
commit: 4642af80fdc23fafed5c0385e3de4e060cc95106
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sat Nov 15 08:40:06 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sat Nov 15 08:40:06 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=4642af80
update AUTHORS
---
AUTHORS | 2 ++
1 file changed, 2 insertions(+)
diff --git a/AUTHORS b/AUTHORS
index 22b4a72..ea030a3 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -1,3 +1,5 @@
Baptiste Daroussin <baptiste.daroussin@gmail.com>
David Durrleman <dualmoo@gmail.com>
oberyno <oberyno@gmail.com>
+Tim Harder <radhermit@gentoo.org>
+Vadim A. Misbakh-Soloviov <mva@mva.name>
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-11-15 9:03 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-11-15 9:03 UTC (permalink / raw
To: gentoo-commits
commit: a47a9eed6cfcb7662c0fe4674fdfbc450cca2448
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sat Nov 15 08:49:36 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sat Nov 15 08:49:36 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=a47a9eed
add _openrc to widgets to be installed and update snapshot name
---
create-dist-xz.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/create-dist-xz.sh b/create-dist-xz.sh
index b69967b..adcbc1b 100755
--- a/create-dist-xz.sh
+++ b/create-dist-xz.sh
@@ -3,10 +3,10 @@
: ${TAR:=$(which tar)}
EXTRA_DIST="AUTHORS"
-COMPLETION_WIDGETS="_eselect _gcc-config _genlop _gentoolkit _gentoo_packages _layman _portage _portage_utils"
+COMPLETION_WIDGETS="_eselect _gcc-config _genlop _gentoolkit _gentoo_packages _layman _openrc _portage _portage_utils"
snapshot_date="$(date +%Y%m%d)"
-snapshot_dir="zsh-completion-${snapshot_date}"
+snapshot_dir="gentoo-zsh-completions-${snapshot_date}"
if [[ -d ${snapshot_dir} ]]; then
rm -rf ${snapshot_dir}
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-11-23 21:35 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2014-11-23 21:35 UTC (permalink / raw
To: gentoo-commits
commit: ba00bafe3bddfb9c0c06134851b0046563c31413
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Fri Nov 21 14:04:51 2014 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Fri Nov 21 14:04:51 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=ba00bafe
remove create dist script
We'll make regular, tagged releases from now on.
---
create-dist-xz.sh | 25 -------------------------
1 file changed, 25 deletions(-)
diff --git a/create-dist-xz.sh b/create-dist-xz.sh
deleted file mode 100755
index adcbc1b..0000000
--- a/create-dist-xz.sh
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/bash
-
-: ${TAR:=$(which tar)}
-
-EXTRA_DIST="AUTHORS"
-COMPLETION_WIDGETS="_eselect _gcc-config _genlop _gentoolkit _gentoo_packages _layman _openrc _portage _portage_utils"
-
-snapshot_date="$(date +%Y%m%d)"
-snapshot_dir="gentoo-zsh-completions-${snapshot_date}"
-
-if [[ -d ${snapshot_dir} ]]; then
- rm -rf ${snapshot_dir}
- mkdir ${snapshot_dir}
-else
- mkdir ${snapshot_dir}
-fi
-
-for i in ${EXTRA_DIST}; do
- cp ${i} ${snapshot_dir}
-done
-for i in ${COMPLETION_WIDGETS}; do
- cp ${i} ${snapshot_dir}
-done
-
-${TAR} -Jcf ${snapshot_dir}.tar.xz ${snapshot_dir}
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-12-18 16:59 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-12-18 16:59 UTC (permalink / raw
To: gentoo-commits
commit: 4624a1aa61e7a75c5490c18169890a312e1b6dae
Author: Vadim A. Misbakh-Soloviov <msva <AT> users <DOT> noreply <DOT> github <DOT> com>
AuthorDate: Wed Dec 3 05:57:04 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Wed Dec 3 05:57:04 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=4624a1aa
Merge pull request #2 from dset0x/equery-completions
_gentoolkit: add missing equery command completions'
src/_gentoolkit | 3 +++
1 file changed, 3 insertions(+)
^ permalink raw reply [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2014-12-20 23:39 Tim Harder
0 siblings, 0 replies; 41+ messages in thread
From: Tim Harder @ 2014-12-20 23:39 UTC (permalink / raw
To: gentoo-commits
commit: 95ac9426fe5352f21c1f183cb6610c55601ee842
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Sat Dec 20 23:36:56 2014 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Sat Dec 20 23:36:56 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/zsh-completion.git;a=commit;h=95ac9426
use reStructuredText for the readme
In order to render it in a better fashion on github. In addition, we
might add more docs or explanations later such as contributing
guidelines.
---
README | 1 -
README.rst | 5 +++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/README b/README
deleted file mode 100644
index c5dfd65..0000000
--- a/README
+++ /dev/null
@@ -1 +0,0 @@
-ZSH Completion Scripts for Gentoo
diff --git a/README.rst b/README.rst
new file mode 100644
index 0000000..23ef3a7
--- /dev/null
+++ b/README.rst
@@ -0,0 +1,5 @@
+gentoo-zsh-completions
+======================
+
+This project focuses on providing Zsh completion support to various Gentoo
+tools that lack completion scripts upstream.
^ permalink raw reply related [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2015-04-28 12:07 Vadim A. Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim A. Misbakh-Soloviov @ 2015-04-28 12:07 UTC (permalink / raw
To: gentoo-commits
commit: e86896ed75a95bf390ef6c304056edeafad56c32
Author: Vadim A. Misbakh-Soloviov <msva <AT> users <DOT> noreply <DOT> github <DOT> com>
AuthorDate: Wed Apr 1 08:21:56 2015 +0000
Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
CommitDate: Wed Apr 1 08:21:56 2015 +0000
URL: https://gitweb.gentoo.org/proj/zsh-completion.git/commit/?id=e86896ed
Merge pull request #4 from ncaq/master
_gentoolkit: add missing equery arg -N or --no-pipe
src/_gentoolkit | 1 +
1 file changed, 1 insertion(+)
^ permalink raw reply [flat|nested] 41+ messages in thread
* [gentoo-commits] proj/zsh-completion:master commit in: /
@ 2023-01-17 14:48 Vadim Misbakh-Soloviov
0 siblings, 0 replies; 41+ messages in thread
From: Vadim Misbakh-Soloviov @ 2023-01-17 14:48 UTC (permalink / raw
To: gentoo-commits
commit: 5463b21054d964c579ace0379e1c7823343cffec
Author: Vadim Misbakh-Soloviov <mva <AT> gentoo <DOT> org>
AuthorDate: Tue Jan 17 14:47:58 2023 +0000
Commit: Vadim Misbakh-Soloviov <mva <AT> gentoo <DOT> org>
CommitDate: Tue Jan 17 14:48:19 2023 +0000
URL: https://gitweb.gentoo.org/proj/zsh-completion.git/commit/?id=5463b210
AUTHORS: fix mva's email
Signed-off-by: Vadim Misbakh-Soloviov <mva <AT> gentoo.org>
AUTHORS | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/AUTHORS b/AUTHORS
index ea030a3..9218ef4 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -2,4 +2,4 @@ Baptiste Daroussin <baptiste.daroussin@gmail.com>
David Durrleman <dualmoo@gmail.com>
oberyno <oberyno@gmail.com>
Tim Harder <radhermit@gentoo.org>
-Vadim A. Misbakh-Soloviov <mva@mva.name>
+Vadim A. Misbakh-Soloviov <mva@gentoo.org>
^ permalink raw reply related [flat|nested] 41+ messages in thread
end of thread, other threads:[~2023-01-17 14:48 UTC | newest]
Thread overview: 41+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-30 11:00 [gentoo-commits] proj/zsh-completion:master commit in: / Tim Harder
-- strict thread matches above, loose matches on Subject: below --
2023-01-17 14:48 Vadim Misbakh-Soloviov
2015-04-28 12:07 Vadim A. Misbakh-Soloviov
2014-12-20 23:39 Tim Harder
2014-12-18 16:59 Tim Harder
2014-11-23 21:35 Vadim A. Misbakh-Soloviov
2014-11-15 9:03 Tim Harder
2014-11-15 8:40 Tim Harder
2014-08-30 10:19 Vadim A. Misbakh-Soloviov
2014-08-30 10:19 Vadim A. Misbakh-Soloviov
2014-08-26 18:51 Vadim A. Misbakh-Soloviov
2014-08-26 4:46 Vadim A. Misbakh-Soloviov
2014-08-25 16:13 Vadim A. Misbakh-Soloviov
2014-08-25 12:41 Vadim A. Misbakh-Soloviov
2014-08-25 12:41 Vadim A. Misbakh-Soloviov
2014-08-25 11:26 Vadim A. Misbakh-Soloviov
2014-03-30 11:00 Tim Harder
2014-03-30 11:00 Tim Harder
2014-03-30 11:00 Tim Harder
2014-03-30 11:00 Tim Harder
2014-03-30 11:00 Tim Harder
2014-03-30 11:00 Tim Harder
2014-03-29 8:38 Tim Harder
2014-03-29 2:35 Tim Harder
2014-03-29 1:41 Tim Harder
2014-03-29 1:41 Tim Harder
2014-03-29 1:41 Tim Harder
2014-03-28 19:46 Tim Harder
2014-03-28 18:59 Tim Harder
2014-03-28 18:59 Tim Harder
2014-03-28 18:59 Tim Harder
2014-03-28 18:42 Tim Harder
2014-03-28 18:36 Tim Harder
2014-03-28 18:18 Tim Harder
2014-03-28 18:18 Tim Harder
2014-01-24 1:29 Tim Harder
2014-01-24 1:05 Tim Harder
2014-01-24 1:05 Tim Harder
2014-01-24 1:05 Tim Harder
2013-02-07 20:15 Tim Harder
2013-02-07 20:15 Tim Harder
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox