diff options
Diffstat (limited to 'Completion/Unix/Command')
-rw-r--r-- | Completion/Unix/Command/_gs | 2 | ||||
-rw-r--r-- | Completion/Unix/Command/_imagemagick | 8 | ||||
-rw-r--r-- | Completion/Unix/Command/_java | 6 | ||||
-rw-r--r-- | Completion/Unix/Command/_last | 28 | ||||
-rw-r--r-- | Completion/Unix/Command/_links | 29 | ||||
-rw-r--r-- | Completion/Unix/Command/_lsof | 4 | ||||
-rw-r--r-- | Completion/Unix/Command/_mount | 22 | ||||
-rw-r--r-- | Completion/Unix/Command/_perldoc | 6 | ||||
-rw-r--r-- | Completion/Unix/Command/_user_admin | 16 | ||||
-rw-r--r-- | Completion/Unix/Command/_yp | 26 | ||||
-rw-r--r-- | Completion/Unix/Command/_zdump | 7 |
11 files changed, 81 insertions, 73 deletions
diff --git a/Completion/Unix/Command/_gs b/Completion/Unix/Command/_gs index fceedcea7..22f3c789b 100644 --- a/Completion/Unix/Command/_gs +++ b/Completion/Unix/Command/_gs @@ -15,7 +15,7 @@ else '-q[quiet startup]' \ '-g-[set device size]:device size (<width>x<height>):' \ '-r-[set resolution]:resolution (<val> or <x>x<y>):' \ - '-I[add search paths]:search paths:_dir_list' \ + '-I[add to library file search path]:directory:_dir_list' \ \*-{d,D}'-[define name with definition]:def:->dname' \ \*-{s,S}'-[define name with value]:def:->sname' \ '*:PostScript or PDF file:_pspdf' && ret=0 diff --git a/Completion/Unix/Command/_imagemagick b/Completion/Unix/Command/_imagemagick index a47e28cfc..5abae4425 100644 --- a/Completion/Unix/Command/_imagemagick +++ b/Completion/Unix/Command/_imagemagick @@ -49,7 +49,7 @@ case "$service" in '*-filter:filter type for resizing:(Point Box Triangle Hermite Hanning Hamming Blackman Gaussian Quadratic Cubic Catrom Mitchell Lanczos Bessel Sinc)' \ '*-flip[vertical mirror image]' \ '*-flop[horizontal mirror image]' \ - '*-font:_x_font' \ + '*-font:font:_x_font' \ '*-foreground:color:_x_color' \ '*-frame:border dimensions (<width>x<height>+<out>+<in>)' \ '*-gamma[gamma correction level]:gamma correction level (<n> or <red>/<green>/<blue>)' \ @@ -84,7 +84,7 @@ case "$service" in '*-shared_memory' \ '*-sharpen:sharpening factor (0.0 - 99.9%%)' \ '*-size:image size (<width>x<height>+<offset>)' \ - '*-text_font:_x_font' \ + '*-text_font:font:_x_font' \ '*-texture:background texture image:_imagemagick' \ '*-title:image title' \ '*-treedepth:color reduction tree depth' \ @@ -117,7 +117,7 @@ case "$service" in '*-depth:image depth:(8 16)' \ '*-display:display:_x_display' \ '*-dither[apply dithering]' \ - '*-font:_x_font' \ + '*-font:font:_x_font' \ '*-foreground:color:_x_color' \ '*-gamma[gamma correction level]:gamma correction level (<n> or <red>/<green>/<blue>)' \ '*+gamma[gamma correction level (don'\''t change pixels)]:gamma correction level (<n> or <red>/<green>/<blue>)' \ @@ -138,7 +138,7 @@ case "$service" in '*-scenes:image scene number' \ '*-shared_memory' \ '*-size:image size (<width>x<height>+<offset>)' \ - '*-text_font:_x_font' \ + '*-text_font:font:_x_font' \ '*-title:image title' \ '*-treedepth:color reduction tree depth' \ '*-trim' \ diff --git a/Completion/Unix/Command/_java b/Completion/Unix/Command/_java index 3faf10273..f6565bc64 100644 --- a/Completion/Unix/Command/_java +++ b/Completion/Unix/Command/_java @@ -27,7 +27,7 @@ javac) jdb) jdb_args=( - '-host[specify hostname to connect]:hostname:_hosts' + '-host[specify host to connect to]:host:_hosts' '-password[specify password]:password:' ) ;& @@ -140,7 +140,7 @@ javah|javah_g) '-bootclasspath[specify path for bootstrap class files]:bootstrap class path:->bootstrapclasspath' \ '-old[generate old JDK1.0-style header files]' \ '-force[force output]' \ - '*:fully qualified classname:_java_class -m main ${(kv)opt_args[(i)-classpath]}' && return 0 + '*:class:_java_class -m main ${(kv)opt_args[(i)-classpath]}' && return 0 ;; javap) @@ -187,7 +187,7 @@ rmic) rmiregistry) if (( CURRENT == 2 )); then - _wanted ports expl 'port to listen' _ports && return + _wanted ports expl 'port to listen on' _ports && return else _message 'no more arguments' fi diff --git a/Completion/Unix/Command/_last b/Completion/Unix/Command/_last index 56537bf84..3e4d84f00 100644 --- a/Completion/Unix/Command/_last +++ b/Completion/Unix/Command/_last @@ -1,17 +1,17 @@ #compdef last lastb _arguments \ - '-a[display hostname in last column]' \ - '-n[number]:number' \ - '-[number]:number' \ - '-f[filename]:filename:_files' \ - '-R[suppress display of hostname field]' \ - '-d[translate IP to hostname]' \ - '-i[display IP]' \ - '-o[read old-format wtmp]' \ - '-x[display shutdown/runlevel entries]' \ - '-h[hostname]:_hosts' \ - '-s[report duration in seconds]' \ - '-t[tty]:tty:' \ - '-w[widen duration field]' \ - '*:user:_users' + '-a[display hostname in last column]' \ + '-n[number]:number' \ + '-[number]:number' \ + '-f[filename]:filename:_files' \ + '-R[suppress display of hostname field]' \ + '-d[translate IP to hostname]' \ + '-i[display IP]' \ + '-o[read old-format wtmp]' \ + '-x[display shutdown/runlevel entries]' \ + '-h[hostname]:host:_hosts' \ + '-s[report duration in seconds]' \ + '-t[tty]:tty' \ + '-w[widen duration field]' \ + '*:user:_users' diff --git a/Completion/Unix/Command/_links b/Completion/Unix/Command/_links index c8a4995d5..464068d46 100644 --- a/Completion/Unix/Command/_links +++ b/Completion/Unix/Command/_links @@ -5,25 +5,25 @@ typeset -A opt_args _arguments -C \ '(-help)-anonymous[restrict links so that it can run on an anonymous account]' \ - '(-help)-assume-codepage[use the given codepage when the webpage did not specify its]:codepage:' \ + '(-help)-assume-codepage[specify default codepage to use]:codepage' \ '(-help)-async-dns[asynchronous DNS resolver]:bool:((0\:on 1\:off))' \ '(-help)-download-dir[default download directory]:_files -/' \ '(-help)-driver[graphics driver to use]:graphics driver:->graphics_drivers' \ '(-help)-dump[dump the page as pure text]' \ - '(-help)-format-cache-size[number of formatted document pages cached]:pages:' \ - '(-help)-ftp-proxy[host and port number of the FTP proxy, or blank]:hostport:_hosts' \ + '(-help)-format-cache-size[number of formatted document pages cached]:pages' \ + '(-help)-ftp-proxy[specify ftp proxy server]:proxy:->proxies' \ '(-help)-g[run in graphics mode rather than plain text mode]' \ '-help[prints the help screen]' \ - '(-help)-http-proxy[host and port number of the HTTP proxy, or blank]:hostport:_hosts' \ - '(-help)-image-cache-size[image cache memory]:kilobytes:' \ - '(-help)-max-connections[maximum number of concurrent connections]:max:' \ - '(-help)-max-connections-to-host[maximum number of concurrent connection to a given host]:max:' \ - '(-help)-memory-cache-size[cache memory]:kilobytes:' \ + '(-help)-http-proxy[specify web proxy server]:proxy:->proxies' \ + '(-help)-image-cache-size[image cache memory]:memory (kilobytes)' \ + '(-help)-max-connections[maximum number of concurrent connections]:connections' \ + '(-help)-max-connections-to-host[maximum number of concurrent connection to a given host]:connections' \ + '(-help)-memory-cache-size[cache memory]:kilobytes' \ '(-help)-no-connect[runs links as a separate instance]' \ - '(-help)-receive-timeout[timeout on receive]:secs:' \ + '(-help)-receive-timeout[timeout on receive]:timeout (seconds)' \ '(-help)-retries[number of retries]:retries' \ '(-help)-source[dump the source page]' \ - '(-help)-unrestartable-receive-timeout[timeout on non restartable connections]:secs:' \ + '(-help)-unrestartable-receive-timeout[timeout on non restartable connections]:timeout (seconds)' \ '(-help)-version[prints the links version number and exit]' \ ':URL:->html' && ret=0 @@ -35,6 +35,15 @@ case $state in vals=(${=${${${(f)"$(_call_program links-graphics-drivers links -driver help 2>&1)"}[-1]}//','/''}} ) _describe -t links-graphics-drivers 'graphics driver' vals && ret=0 ;; + proxies) + local suf=-S: + if compset -P '*:'; then + _message -e ports 'port number' + else + compset -S ':*' && suf= + _hosts $suf && ret=0 + fi + ;; esac return ret diff --git a/Completion/Unix/Command/_lsof b/Completion/Unix/Command/_lsof index 0e3bc7a1b..aca9963c2 100644 --- a/Completion/Unix/Command/_lsof +++ b/Completion/Unix/Command/_lsof @@ -27,7 +27,7 @@ _arguments -s -S \ '(-s)-o[list file offset]' \ '-O[avoid overheads of bypassing potential blocking]' \ '-P[inhibit conversion of port numbers to port names]' \ - '-p[list files for specified processes]:processes:_pids' \ + '-p[list files for specified processes]:process ID:_pids' \ '-r[repeat listing endlessly]::delay (seconds)' \ '+r[repeat listing until no files listed]::delay (seconds)' \ '-R[list parent PID]' \ @@ -35,7 +35,7 @@ _arguments -s -S \ '-S[specify timeout for kernel functions that might deadlock]:timeout (seconds)' \ '-T[select reporting of TCP/TPI info]::info type:((q\:queue\ length\ reporting s\:state\ reporting w\:window\ size\ reporting))' \ '(+w -w)-t[terse output]' \ - '-u[list files owned by specified users]:user list:_users' \ + '-u[list files owned by specified users]:user:_users -S,' \ '-U[list Unix domain socket files]' \ '(-)-v[list version info]' \ '-V[indicate unsuccessfully searched for items]' \ diff --git a/Completion/Unix/Command/_mount b/Completion/Unix/Command/_mount index d905664c7..f19da0869 100644 --- a/Completion/Unix/Command/_mount +++ b/Completion/Unix/Command/_mount @@ -24,8 +24,8 @@ if [[ "$OSTYPE" == cygwin ]]; then local -a wpaths upaths mount | while read -r line; do [[ $line == ?:\ * ]] && continue - wpaths=($wpaths ${line%% on*}) - upaths=($upaths ${${line##*on }%% type*}) + wpaths+=( ${line%% on*} ) + upaths+=( ${${line##*on }%% type*} ) done _alternative \ 'windowspath:Windows path:compadd -a wpaths' \ @@ -552,10 +552,10 @@ if [[ "$service" = mount ]]; then irix*) args=( -s '-a[mount all filesystems in /etc/fstab]' - '-b[mount all filesystems in /etc/fstab except those listed]:list of directories:_dir_list -s,' + '-b[mount all filesystems in /etc/fstab except those listed]:mount point:_dir_list -s,' '-c[check any dirty filesystems before mounting]' "-f[fake a new /etc/mtab entry, but don't mount any filesystems]" - '-h[mount all filesystems associated with host]:hostnames:_hosts' + '-h[mount all filesystems associated with host]:host:_hosts' '-n[mount filesystem without making entry in /etc/mtab]' '-o[specify file system options]:file system option:->fsopt' '-p[print list of mounted filesystems in format suitable for /etc/fstab]' @@ -681,8 +681,8 @@ else irix*) args=( '-a[unmount all mounted file systems]' - '-b[unmount all filesystems in /etc/fstab except those listed]:list of directories:_dir_list -s,' - '-h[unmount all filesystems associated with host]:hostnames:_hosts' + '-b[unmount all filesystems in /etc/fstab except those listed]:mount point:_dir_list -s,' + '-h[unmount all filesystems associated with host]:host:_hosts' '-k[kill all processes with files open on filesystems before unmounting]' '-t[unmount all filesystems of specified type]:file system type:_file_systems' '-v[verbose]' @@ -709,7 +709,7 @@ else '(*)-a[unmount all mounted file systems]' '-A[unmount all mounted file systems except the root]' '-f[force unmount]' - '-h[unmount all filesystems associated with host]:hostnames:_hosts' + '-h[unmount all filesystems associated with host]:host:_hosts' '-t[unmount all filesystems of specified type]:file system type:->fslist' '-v[verbose mode]' '*:dev or dir:->udevordir' @@ -775,8 +775,8 @@ devordir) ;; *) [[ $mline[(w)3] == swap ]] || \ - dev_tmp=( $dev_tmp $mline[(w)1] ) \ - mp_tmp=( $mp_tmp $mline[(w)2] ) + dev_tmp+=( $mline[(w)1] ) \ + mp_tmp+=( $mline[(w)2] ) ;; esac done < /etc/fstab @@ -808,8 +808,8 @@ udevordir) ;; *) /sbin/mount | while read mline; do - mp_tmp=( $mp_tmp $mline[(w)1] ) - dev_tmp=( $dev_tmp $mline[(w)3] ) + mp_tmp+=( $mline[(w)1] ) + dev_tmp+=( $mline[(w)3] ) done ;; esac diff --git a/Completion/Unix/Command/_perldoc b/Completion/Unix/Command/_perldoc index 869dbae3a..7a3d806c5 100644 --- a/Completion/Unix/Command/_perldoc +++ b/Completion/Unix/Command/_perldoc @@ -49,9 +49,9 @@ case $state in _files -g "*.(pod|pm)(-.)" && ret=0 else _alternative \ - 'modules:: _perl_modules' \ - 'pods:: _perl_basepods' \ - 'files:Perl modules and .pods:_files -g "*.(pod|pm)(-.)"' && ret=0 + 'modules:module: _perl_modules' \ + 'pods:base pod: _perl_basepods' \ + 'files:module or .pod file:_files -g "*.(pod|pm)(-.)"' && ret=0 fi ;; esac diff --git a/Completion/Unix/Command/_user_admin b/Completion/Unix/Command/_user_admin index 4e7c1d487..281171d17 100644 --- a/Completion/Unix/Command/_user_admin +++ b/Completion/Unix/Command/_user_admin @@ -18,23 +18,23 @@ if [[ $service = user* ]]; then '(-D)-e+[specify expiration date]:expiration date (YYYY-MM-DD)' '(-D)-f+[specify inactive days]:inactive days' '(-D)-g+[initial group]:initial group:_groups' - '(-D)-G+[supplementary groups]:supplementary groups:_groups -S,' + '(-D)-G+[supplementary groups]:supplementary group:_groups -S,' "(-D)-s+[shell]:shell:( $shells /bin/false )" '(-D -M)-m[create home directory]' '(-D)-u[uid]:uid' '(-D)-o[allow non unique uid]' ) - [[ $OSTYPE = linux* ]] && args=( $args[@] + [[ $OSTYPE = linux* ]] && args+=( '(-D -U -L)-p+[specify encrypted password]:encrypted password' ) if [[ $service = useradd ]]; then - (( redhat )) || args=( $args[@] + (( redhat )) || args+=( "(-D -k -m)-M[don't create home]" '(-D)-r[create system account]' "(-D)-n[don't create mirrored user]" ) [[ $OSTYPE = linux* ]] || sun=" -s" - args=( $args[@] + args+=( "(-c -G -m -k -M -p -u -o -n -r$sun)-D[modify or display defaults]" '(-D -M)-k[skeleton home directory]:skeleton directory:_directories -W /' ':username' @@ -44,7 +44,7 @@ if [[ $service = user* ]]; then "(-U -p)-L[lock user's password]" "(-L -p)-U[unlock user's password]" ) - args=( $args[@] + args+=( '-l[specify new user name]:new username' ':username:_users' ) @@ -52,15 +52,15 @@ if [[ $service = user* ]]; then else args=( '-g+[gid]:gid' '-o[allow non unique gid]' ) if [[ $service = groupadd ]]; then - args=( $args[@] ':group name' ) + args+=( ':group name' ) (( redhat )) || args=( $args[@] '-r[create system group]' '-f[force]' ) else - args=( $args[@] + args+=( '-n[specify new group name]:new group name' - ':group name:_groups' + ':group:_groups' ) fi fi diff --git a/Completion/Unix/Command/_yp b/Completion/Unix/Command/_yp index 128de36b7..104a0b4df 100644 --- a/Completion/Unix/Command/_yp +++ b/Completion/Unix/Command/_yp @@ -1,13 +1,13 @@ #compdef ypcat ypmatch yppasswd ypwhich ypset ypserv ypbind yppush yppoll ypxfr domainname -local curcontext="$curcontext" line state ret=1 +local curcontext="$curcontext" line state expl ret=1 typeset -A opt_args if (( ! $+_yp_cache_maps )); then _yp_cache_maps=( "${(@)${(@f)$(_call_program maps ypwhich -m)}%% *}" ) _yp_cache_nicks=( "${(@)${(@)${(@f)$(_call_program names ypwhich -x)}#*\"}%%\"*}" ) _yp_args=( - '(-x)-d[specify domain]:domain name:' \ + '(-x)-d[specify domain]:domain name' \ '(-x)-k[display keys]' \ '(-x)-t[inhibit nicknames]' \ '(: -d -k -t)-x[display nicknames]' \ @@ -28,7 +28,7 @@ yppasswd) ;; ypwhich) _arguments -C \ - '(-x)-d[specify domain]:domain name:' \ + '(-x)-d[specify domain]:domain name' \ '(-x -V2 -m -t)-V1[identify version 1 servers]' \ '(-x -V1 -m -t)-V2[identify version 2 servers]' \ '(: -x -V1 -V2 -m)-t[specify map name]:map name:->maponly' \ @@ -40,8 +40,8 @@ ypset) _arguments -C \ '(-V2)-V1[bind version 1 servers]' \ '(-V1)-V2[bind version 2 servers]' \ - '-d[specify domain]:domain name:' \ - '-h[specify host]:set binding on host:_hosts' \ + '-d[specify domain]:domain name' \ + '-h[set NIS binding on specified host]:host:_hosts' \ ':server:_hosts' && ret=0 ;; ypserv) @@ -57,24 +57,24 @@ ypbind) ;; yppush) _arguments -C \ - '-d[specify domain]:domain name:' \ + '-d[specify domain]:domain name' \ '-v[print messages]' \ ':map name:->map' && ret=0 ;; yppoll) _arguments -C \ - '-d[specify domain]:domain name:' \ - '-h[specify host]:ask server on host:_hosts' \ + '-d[specify domain]:domain name' \ + '-h[ask specified yp server]:host:_hosts' \ ':map name:->map' && ret=0 ;; ypxfr) _arguments -C \ '-a[specify database routines]:database routines:((b\:btree d\:dbm/ndbm h\:hash))' \ '-f[force transfer]' \ - '-c[don'"'"'t clear current map]' \ - '-d[specify domain]:domain name:' \ - '-h[specify host]:get map from host:_hosts' \ - '-C[call back]:transaction ID: :program number: :IP address: :port number:' \ + "-c[don't clear current map]" \ + '-d[specify domain]:domain name' \ + '-h[get map from specified host instead of master]:host:_hosts' \ + '-C[call back]:transaction ID: :program number: :IP address: :port number' \ ':map name:->map' && ret=0 ;; domainname) @@ -86,8 +86,6 @@ esac [[ "$state" = keymap ]] && _message -e keys 'key' if [[ "$state" = map* ]]; then - local expl - if [[ $+opt_args[-t] -eq 0 && "$state" != maponly ]]; then _tags maps nicknames else diff --git a/Completion/Unix/Command/_zdump b/Completion/Unix/Command/_zdump index 1d186d4e3..f96bdd764 100644 --- a/Completion/Unix/Command/_zdump +++ b/Completion/Unix/Command/_zdump @@ -1,5 +1,6 @@ #compdef zdump -_arguments '-v[lowest possible]' \ - '-c[cutoff]:cutoff year:' \ - '*:timezone:_time_zone' +_arguments \ + '-v[lowest possible]' \ + '-c[cutoff]:cutoff year:' \ + '*:time zone:_time_zone' |