about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--Completion/Unix/Command/_bogofilter130
-rw-r--r--Completion/Unix/Command/_chkconfig28
-rw-r--r--Completion/Unix/Command/_chmod82
-rw-r--r--Completion/Unix/Command/_gs57
-rw-r--r--Completion/Unix/Command/_look16
-rw-r--r--Completion/Unix/Command/_python38
-rw-r--r--Completion/Unix/Command/_rar132
-rw-r--r--Completion/Unix/Type/_file_systems10
-rw-r--r--Completion/Unix/Type/_global_tags7
-rw-r--r--Completion/Unix/Type/_locales12
-rw-r--r--Completion/Unix/Type/_user_at_host31
-rw-r--r--Completion/X/Command/_netscape93
-rw-r--r--Completion/X/Type/_x_visual10
-rw-r--r--Completion/Zsh/Command/_disable9
-rw-r--r--Completion/Zsh/Context/_equal5
15 files changed, 655 insertions, 5 deletions
diff --git a/Completion/Unix/Command/_bogofilter b/Completion/Unix/Command/_bogofilter
new file mode 100644
index 000000000..9e6ac3f88
--- /dev/null
+++ b/Completion/Unix/Command/_bogofilter
@@ -0,0 +1,130 @@
+#compdef bogoutil bogotune bogofilter
+
+local expl ret bogotokens
+
+_bogoutil_caching_policy () {
+
+  # rebuild if cache is more than a week old
+  oldp=( "$1"(mw+1) )
+  (( $#oldp )) && return 0
+
+  return 1
+}
+
+_bogoutil() {
+
+	typeset -a _bogoutil_actions
+	_bogoutil_actions=(-h --help -V --version -d --dump -l --load -u
+		--upgrade -m -w -p -H --db-verify -r -R --db-prune --db-recover
+		--db-recover-harder --db-remove-environment -k --db-cachesize)
+
+  _arguments -s \
+  	'*'{-v,--verbosity}'[verbose]' \
+  	'-n[replace non-ASCII characters]' \
+	{-D,--debug-to-stdout}'[redirect debug output to stdout]' \
+  	'-a[acceptable token age]:date or day count' \
+  	'-c[acceptable count]:count threshold' \
+  	'-s[acceptable size range]:min-max range' \
+	{-y,--timestamp-date=}'[date for when unknown]:date in YYYYMMDD format' \
+	'(--input-file -I)'{-I,--input-file=}'[input file]:input file:_files' \
+	{-x,--debug-flags=}'[debug flags]:debug flags:' \
+	"($_bogoutil_actions)"{-d,--dump=}'[print contents of db]:database file:_files -g "*.db"' \
+  	"($_bogoutil_actions)"{-l,--load=}'[load file into db]:textfile:_files' \
+	"($_bogoutil_actions)"{-u,--upgrade=}'[upgrade wordlist version]:database file:_files -g "*.db"' \
+	"($_bogoutil_actions)"'-m[perform maintenance functions]:file:_files' \
+  	"($_bogoutil_actions)"'-w[display token information]:database file or directory:_files' \
+  	"($_bogoutil_actions)"'-p[display token probability information]:database file or directory:_files' \
+	"($_bogoutil_actions)"'-H[print histogram]:database file or directory:_files' \
+	"($_bogoutil_actions)"'-r[recalculate ROBX]:database:_files -/' \
+	"($_bogoutil_actions)"'-R[recalculate and save ROBX]:database:_files -/' \
+	"($_bogoutil_actions)"{-k,--db-cachesize=}'[set Berkeley DB cache size]:size in MB:' \
+	"($_bogoutil_actions)"'--db-verify[verify database]:database:_files -/' \
+	"($_bogoutil_actions)"'--db-recover[run regular recovery]:database:_files -/' \
+	"($_bogoutil_actions)"'--db-recover-harder[run catastrophic recovery]:database:_files -/' \
+	"($_bogoutil_actions)"'--db-prune[checkpoint database]:database:_files -/' \
+	"($_bogoutil_actions)"'--db-remove-environment:database:_files -/' \
+	'--db_lk_max_locks[set max lock count]' \
+	'--db_lk_max_objects[set max object count]' \
+  	"($_bogoutil_actions)"'-h[help]' \
+  	"($_bogoutil_actions)"'--help' \
+  	"($_bogoutil_actions)"'-V[version]' \
+  	"($_bogoutil_actions)"'--version' \
+  	'*:tokens:->tokens' && ret=0
+
+  zstyle -s ":completion:${curcontext}:" cache-policy update_policy
+  if [[ -z "$update_policy" ]]; then
+    zstyle ":completion:${curcontext}:" cache-policy _bogoutil_caching_policy
+  fi
+  
+  case $state in
+  	(tokens)
+  	if ( [[ -z "$bogotokens" ]] || _cache_invalid bogotokens ) &&
+  	  ! _retrieve_cache bogotokens; then
+  	  bogotokens=(${${(f)"$(_call_program bogoutil bogoutil -d ~/.bogofilter/wordlist.db -c 50)"}%% *})
+  	  _store_cache bogotokens bogotokens
+  	else
+  	  :
+  	fi
+  	  _wanted tokens expl "token" \
+  	     compadd -a bogotokens
+  	;;
+  esac
+}
+
+case $service in
+	(bogoutil)
+	_bogoutil "$@"
+	;;
+	(bogotune)
+	_arguments \
+	'-h[help]' \
+	'-C[do not read standard configs]' \
+	'-c[config file]:config file:_files' \
+	'-D[do not a wordlist file]' \
+	'-d[wordlist dir]:directory:_files -/' \
+	'-E[disable ESF tuning]' \
+	'-M[output input file in message count format]' \
+	'-r[specify robx value]:robx value:' \
+	'-T[specify fp target value]:fp target value:' \
+	'-s[spam files]:spam files:_files' \
+	'-n[non-spam files]:non-spam files:_files' \
+	'-v[verbose]' \
+	'-q[quiet]'
+	;;
+	(bogofilter)
+	_arguments -s -w \
+	'(--help)-h[help]' \
+	'(--version)-V[version]' \
+	'(--query)-Q[query]' \
+	'-QQ[display extended config info]' \
+	'(--passthrough)-p[passthrough]' \
+	'(--ham-true)-e[ham-true]' \
+	'(--update-as-scored)-u[update-as-scored]' \
+	'(--classify-mbox)-M[classify-mbox]' \
+	'(--classify-stdin)-b[classify-stdin]' \
+	'(--classify-files)-B[classify-files]:file list:_files' \
+	'(--dataframe)-R[print R dataframe]' \
+	'(--register-spam)-s[register as spam]' \
+	'(--register-ham)-n[register as non-spam]' \
+	'(--unregister-spam)-S[unregister as spam]' \
+	'(--unregister-ham)-N[unregister as non-spam]' \
+	'(--config-file)-c[config file]:config file:_files' \
+	'(--no-config-file)-C[do not read standard config files]' \
+	'(--bogofilter_dir)-d[wordlist directory]' \
+	'(--no-header-tags)-H[disable header line tagging]' \
+	'(--db_cachesize)-k[set Berkeley DB cache size]:megabytes:' \
+	'(--use-syslog)-l[log via syslog]' \
+	'(--syslog-tag)-L[specify tag value for log messages]:tag:' \
+	'(--input-file)-I[specify input file instead of stdin]:input file:_files' \
+	'(--output-file)-O[specify output file instead of stdout]:output file:_files' \
+	'(--min_dev --robs --robx)-m[user-defined min_dev, robs, and robx]:values:' \
+	'(--spam_cutoff --ham_cutoff)-o[user-defined spam and ham cutoffs]:values:' \
+	'(--terse)-t[terse output mode]' \
+	'(--fixed-terse-format)-T[invariant terse output mode]' \
+	'(--report-unsure)-U[print statistics if spamicity is unsure]' \
+	'(--verbosity)-v[set debug verbosity level]' \
+	'(--timestamp-date)-y[set date for token timestamps]' \
+	'(--debug-to-stdout)-D[direct debug output to stdout]' \
+	'(--debug-flags)-x[debug flags]:debug flags:'
+	;;
+esac
diff --git a/Completion/Unix/Command/_chkconfig b/Completion/Unix/Command/_chkconfig
new file mode 100644
index 000000000..76da38d27
--- /dev/null
+++ b/Completion/Unix/Command/_chkconfig
@@ -0,0 +1,28 @@
+#compdef chkconfig
+
+local curcontext="$curcontext" state line expl ret=1
+
+case $OSTYPE in
+linux*)
+  _arguments -C \
+    '(- 2)--list[list services]' \
+    '(-)--level[specify runlevels to apply to]:-:_values -s "" "run levels" 1 2 3 4 5 6 7' \
+    '(- 2)--add[add new service]' \
+    '(- 2)--del[remove service from chkconfig management]' \
+    '1:service name:_services' \
+    '2:state:(on off reset)' && ret=0
+;;
+irix*)
+  _arguments -C \
+    '(- 1)-s[print state of configuration flags]' \
+    '(1 -s)-f[set flag state]:configuration flag:->flag:state:(on off)' \
+    '1:configuration flag:->flag' && ret=0
+
+  if [[ -n "$state" ]]; then
+    _wanted conf-flags expl 'configuration flag' \
+	compadd ${${${(f)"$($words[1])"}[4,-1]##$'\t'}%% *} && ret=0
+  fi
+;;
+esac
+
+return ret
diff --git a/Completion/Unix/Command/_chmod b/Completion/Unix/Command/_chmod
new file mode 100644
index 000000000..3df93fd64
--- /dev/null
+++ b/Completion/Unix/Command/_chmod
@@ -0,0 +1,82 @@
+#compdef chmod
+
+local curcontext="$curcontext" state line expl ret=1
+local -a args privs
+
+args=( '*:file:->files' )
+(( $+words[(r)--reference*] )) || args+=( '1:mode:->mode' )
+
+if _pick_variant gnu=Free\ Soft unix --version; then
+  args+=(
+    '(-v --verbose -c --changes)'{-c,--changes}'[report changes made]'
+    '(-v --verbose -c --changes)'{-v,--verbose}'[output a diagnostic for every file processed]'
+    '(-f --silent --quiet)'{-f,--silent,--quiet}'[suppress most error messages]'
+    '--reference=[copy permissions of specified file]:file:_files'
+    '(-R --recursive)'{-R,--recursive}'[change files and directories recursively]'
+    '(- : *)--help[display help information]'
+    '(- : *)--version[display version information]'
+  )
+  privs=(
+    'X[execute only if executable to another]'
+    "u[owner's current permissions]"
+    "g[group's current permissions]"
+    "o[other's current permissions]"
+  )
+else
+  # based on $OSTYPE = solaris2.8
+  args+=(
+    '-f[suppress most error messages]'
+    '-R[change files and directories recursively]'
+  )
+  privs=( 'l[mandatory locking]' )
+fi
+
+_arguments -C -s "$args[@]" && ret=0
+
+case "$state" in
+  mode)
+    compset -P \*,
+    compset -S ,\*
+    if [[ -prefix [0-7] ]]; then
+      _message -e number 'numeric mode'
+    elif compset -P '[a-z]#[+-=]'; then
+      _values -S '' privilege \
+	'r[read]' 'w[write]' 'x[execute]' \
+	's[set uid/gid]' 't[sticky]' \
+	"$privs[@]" && ret=0
+    else
+      suf=( -S '' )
+      compset -P '*'
+      _alternative -O suf \
+	'who:who:((u\:user g\:group a\:all o\:others))' \
+	'operators:operator:(+ - =)'
+    fi
+  ;;
+  files)
+    if [[ -n $opt_args[--reference] ]]; then
+      if zstyle -t ":completion:${curcontext}:" disable-stat; then
+	_files && ret=0
+      else
+	zmodload -i zsh/stat 2>/dev/null
+	typeset -i8 ref=$(stat +mode $opt_args[--reference])
+	_wanted files expl file _files -g "*(-.^f${ref#??})" && ret=0
+      fi
+    elif [[ $words[2] = [0-7]## ]]; then
+      _wanted files expl file _files -g "*(-.^f$words[2])" && ret=0
+    else
+      local spec who op priv
+      local -a specs
+      for spec in ${(s:,:)words[2]}; do
+	if [[ ${spec#*[+-=]} != [rwxst]## ]]; then
+	  _files && ret=0
+	  return ret
+	fi
+
+	specs+=( ${${(M)spec##[+-=]*}:+a}$spec )
+      done
+      _wanted files expl file _files -g "*(-.^f:${(j.,.)specs}:)" && ret=0
+    fi
+  ;;
+esac
+
+return ret
diff --git a/Completion/Unix/Command/_gs b/Completion/Unix/Command/_gs
new file mode 100644
index 000000000..22f3c789b
--- /dev/null
+++ b/Completion/Unix/Command/_gs
@@ -0,0 +1,57 @@
+#compdef gs ghostscript
+
+if compset -N --; then
+  if [[ CURRENT -eq 1 ]]; then
+    _pspdf
+  else
+    _message -e arguments 'userdict ARGUMENTS'
+    return 1
+  fi
+else
+  local curcontext="$curcontext" state line expl ret=1
+  typeset -A opt_args
+
+  _x_arguments -C \
+    '-q[quiet startup]' \
+    '-g-[set device size]:device size (<width>x<height>):' \
+    '-r-[set resolution]:resolution (<val> or <x>x<y>):' \
+    '-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
+
+  case "$state" in
+  dname)
+    if [[ "$PREFIX" = *\=* ]]; then
+      _message -e definition-values 'systemdict definition value'
+    else
+      _wanted names expl 'systemdict definition name' \
+          compadd -M 'm:{a-z}={A-Z}' - \
+                  DISKFONTS NOCACHE NOBIND NODISPLAY NOPAUSE PLATFONTS SAFER \
+                  WRITESYSTEMDICT && ret=0
+    fi
+    ;;
+  sname)
+    if compset -P '*='; then
+      case "$IPREFIX" in
+      *DEVICE\=)
+        _wanted devices expl 'ghostscript device' \
+            compadd - "${(@)${=${$(_call_program devices gs -h)##* devices:}%%Search path:*}:#}" && ret=0
+        ;;
+      *OutputFile\=)
+        _description files expl 'output file'
+        _files "$expl[@]" && ret=0
+        ;;
+      *)
+        _message -e values 'systemdict value'
+        return 1
+      esac
+    else
+      _wanted names expl 'systemdict name' \
+          compadd -S\= -M 'm:{a-z}={A-Z}' - DEVICE OutputFile && ret=0
+    fi
+    ;;
+  esac
+
+  return ret
+fi
diff --git a/Completion/Unix/Command/_look b/Completion/Unix/Command/_look
new file mode 100644
index 000000000..94a90bc3f
--- /dev/null
+++ b/Completion/Unix/Command/_look
@@ -0,0 +1,16 @@
+#compdef look
+
+local curcontext="$curcontext" state line expl ret=1
+typeset -A opt_args
+
+_arguments -C -s \
+  '-t+[termination character]:termination character:' \
+  '-f[case insensitive]' \
+  '-d[dictionary order]' \
+  ':string:->string' \
+  ':dictionary file:_files' && ret=0
+
+[[ -n "$state" && ! -prefix - ]] && _wanted values expl 'word prefix' \
+    compadd - $(_call_program words $words[1] '"$PREFIX"') && return
+
+return ret
diff --git a/Completion/Unix/Command/_python b/Completion/Unix/Command/_python
new file mode 100644
index 000000000..be27f8300
--- /dev/null
+++ b/Completion/Unix/Command/_python
@@ -0,0 +1,38 @@
+#compdef python
+
+# Python 2.4
+
+local curcontext="$curcontext" state line expl
+typeset -A opt_args
+
+_arguments -C -s -S \
+  '(1 -)-c+[program passed in as string (terminates option list)]:python command:' \
+  '-d[debug output from parser]' \
+  '-E[ignore environment variables (such as PYTHONPATH)]' \
+  '(1 * -)-h[display help information]' \
+  '-i[inspect interactively after running script]' \
+  '(1 * -)-m[run library module as a script (terminates option list)]:module:->modules' \
+  '-O[optimize generated bytecode]' \
+  '-OO[remove doc-strings in addition to the -O optimizations]' \
+  '-Q+[division options]:division option:(old warn warnall new)' \
+  "-S[don't imply 'import site' on initialization]" \
+  '-t[issue warnings about inconsistent tab usage]' \
+  '-tt[issue errors about inconsistent tab usage]' \
+  '-u[unbuffered binary stdout and stderr]' \
+  '-v[verbose (trace import statements)]' \
+  '(1 * -)-V[display version information]' \
+  '-W+[warning control]:warning filter (action\:message\:category\:module\:lineno):(default always ignore module once error)' \
+  '-x[skip first line of source, allowing use of non-Unix forms of #!cmd]' \
+  '(-)1:script file:_files -g "*.py(|c|o)(-.)"' \
+  '*::script argument: _normal' && return
+
+if [[ "$state" = modules ]]; then
+  local -a modules
+  modules=(
+    ${${=${(f)"$(_call_program modules $words[1] -c \
+      'from\ pydoc\ import\ help\;\ help\(\"modules\"\)')"}[2,-3]}:#\(package\)}
+  )
+  _wanted modules expl module compadd -a modules && return
+fi
+
+return 1
diff --git a/Completion/Unix/Command/_rar b/Completion/Unix/Command/_rar
new file mode 100644
index 000000000..1e3a26166
--- /dev/null
+++ b/Completion/Unix/Command/_rar
@@ -0,0 +1,132 @@
+#compdef rar unrar
+
+local common expl
+
+common=(
+  '-ad[append archive name to destination path]'
+  '-ap[set path inside archive]'
+  '-av\-[disable authenticity verification check]'
+  '-c\-[disable comments show]'
+  '-cfg\-[disable read configuration]'
+  '-cl\-[convert names to lower case]'
+  '-cu[convert names to upper case]'
+  '-dh[open shared files]'
+  '-ep[exclude paths from name]'
+  '-f[freshen files]'
+  '-idp[disable percentage display]'
+  '-ierr[send all messages to stderr]'
+  '-inul[disable all messages]'
+  '-kb[keep broken extracted files]'
+  '-o\+[overwrite existing files]'
+  '-o\-[do not overwrite existing files]'
+  '-ow[save or restore file owner and group]'
+  '-p+:password'
+  '-p\-[do not query password]'
+  '-r[recurse subdirectorie]'
+  '-ta+[process files modified after a date]:date (YYYYMMDDHHMMSS)'
+  '-tb+[process files modified before a date]:date (YYYYMMDDHHMMSS)'
+  '-tn+[process files newer than a specified time]:time'
+  '-to+[process files older than a specified time]:time'
+  '-u[update files]'
+  '-v[create volumes with size autodetection or list all volumes]'
+  '-ver[file version control]'
+  '-vp[pause before each volume]'
+  '-x[exclude specified file]'
+  '-y[assume yes answer to all queries]'
+)
+
+case $service in
+  unrar)
+    if (( CURRENT == 2 )); then
+       _values 'rar command' \
+	'e[extract files to current directory]' \
+	'l[list archive]' \
+	'lt[list archive (technical format)]' \
+	'lb[list archive (bare format)]' \
+	'p[print file to stdout]' \
+	't[test archive files]' \
+	'v[verbosely list archive]' \
+	'vt[verbosely list archive (technical format)]' \
+	'vb[verbosely list archive (bare format)]' \
+	'x[extract files with full path]' && return
+    else
+      _arguments -S \
+	'-ep3[expand paths to full including the drive letter]' \
+        '-idc[disable ___ display]' \
+        '-idd[disable ___ display]' \
+        '-idq[disable ___ display]' \
+	'-n+:file to include:_files' \
+	'-n@+:file of files to include:_files' \
+        "$common[@]" \
+        '*:RAR files:_files -g \*.rar\(-.\)' && return
+    fi
+  ;;
+  rar)
+    if (( CURRENT == 2 )); then
+      _values 'rar command' \
+	'a[add files to archive]' \
+	'c[add archive comment]' \
+	'cf[add files comment]' \
+	'cw[write archive comment to file]' \
+	'd[delete files from archive]' \
+	'e[extract files to current directory]' \
+	'f[freshen files in archive]' \
+	'i[find string in archives]' \
+	'k[lock archive]' \
+	'l[list archive]' \
+	'lt[list archive (technical format)]' \
+	'lb[list archive (bare format)]' \
+	'm[move to archive]' \
+	'mf[move to archive (files only)]' \
+	'p[print file to stdout]' \
+	'r[repair archive]' \
+	'rc[reconstruct missing volumes]' \
+	'rr[add data recovery record]' \
+	'rv[create recovery volumes]' \
+	's[convert archive to or from SFX]' \
+	't[test archive files]' \
+	'u[update files in archive]' \
+	'v[verbosely list archive]' \
+	'vt[verbosely list archive (technical format)]' \
+	'vb[verbosely list archive (bare format)]' \
+	'x[extract files with full path]' && return
+    else
+      _arguments -S \
+	'-ag[generate archive name using the current date]' \
+	'-as[synchronize archive contents]' \
+	'-av[put authenticity verification (registered versions only)]' \
+	'-df[delete files after archiving]' \
+	'-ds[disable name sort for solid archive]' \
+	'-e[set file exclude attributes]' \
+	'-ed[do not add empty directories]' \
+	'-en[do not put end of archive block]' \
+	'-ep1[exclude base directory from names]' \
+	'-ep2[expand paths to full]' \
+	'-hp[encrypt both file data and headers]' \
+	'-ilog[log errors to file (registered versions only)]' \
+	'-isnd[enable sound]' \
+	'-k[lock archive]' \
+	'-m+[set compression level]:compression level:(( 0\:store 1\:fastest 2\:fast 3\:normal 4\:good 5\:maximal ))' \
+	'-md+[dictionary size]:dictionary size (KB):( 64 128 256 512 1024 2048 4096 a b c d e f g )' \
+	'-ms[specify file types to store]' \
+	'-ol[save symbolic links as the link instead of the file]' \
+	'-p[set password]' \
+	'-r0[recurse subdirectories for wildcard names only]' \
+	'-rr[add data recovery record]' \
+	'-rv[create recovery volumes]' \
+	'-s[create solid archive]' \
+	'-se[create solid archive using extension]' \
+	'-sv[create solid archive using volumes]' \
+	'-s\-[disable solid archiving]' \
+	'-sfx[create SFX archive]' \
+	'-t[test files after archiving]' \
+	'-tk[keep original archive time]' \
+	'-tl[set archive time to latest file]' \
+	'-vn[use the old style volume naming scheme]' \
+	'-w+[assign work directory]:work directory:_files -/' \
+	"$common[@]" \
+	'-z+[read archive comment from file]:comment file:_files' \
+	'*:files:_files' && return
+    fi
+  ;;
+esac
diff --git a/Completion/Unix/Type/_file_systems b/Completion/Unix/Type/_file_systems
index d541fac15..ffbf5ac68 100644
--- a/Completion/Unix/Type/_file_systems
+++ b/Completion/Unix/Type/_file_systems
@@ -1,6 +1,6 @@
 #autoload
 
-local fss
+local expl fss
 
 case $OSTYPE in
   aix*) fss=( jfs nfs cdrfs ) ;;
@@ -10,9 +10,9 @@ case $OSTYPE in
     fss=( adfs bfs cramfs ext2 ext3 hfs hpfs iso9660 minix ntfs qnx4
           reiserfs romfs swap udf ufs vxfs xfs xiafs )
     [[ -r /proc/filesystems ]] &&
-        fss=( $fss ${$(</proc/filesystems)#nodev} )
+        fss+=( ${$(</proc/filesystems)#nodev} )
     [[ -r /etc/filesystems ]] &&
-        fss=( $fss ${$(</etc/filesystems)#nodev} )
+        fss+=( ${$(</etc/filesystems)#\*} )
   ;;
   osf*) fss=( advfs ufs nfs mfs cdfs ) ;;
   solaris*) fss=( ufs nfs hsfs s5fs pcfs cachefs tmpfs ) ;;
@@ -22,11 +22,11 @@ case $OSTYPE in
   ;;
   *)
     # default for all other systems
-    fss=( ufs)
+    fss=( ufs )
   ;;
 esac
 
-_wanted fstypes expl 'file system type' compadd "$@" -M 'L:|no=' -a fss
+_wanted fstypes expl 'file system type' compadd "$@" -M 'L:|no=' -a "$@" - fss
 
 
  
diff --git a/Completion/Unix/Type/_global_tags b/Completion/Unix/Type/_global_tags
new file mode 100644
index 000000000..fcda28dfb
--- /dev/null
+++ b/Completion/Unix/Type/_global_tags
@@ -0,0 +1,7 @@
+#autoload
+
+local expl tags
+
+tags=( $(_call_program global-tags global --completion $PREFIX 2>/dev/null) )
+
+_wanted global-tags expl 'tag' compadd -M 'm:{a-zA-Z}={A-Za-z}' -a "$@" - tags
diff --git a/Completion/Unix/Type/_locales b/Completion/Unix/Type/_locales
new file mode 100644
index 000000000..a449ebe16
--- /dev/null
+++ b/Completion/Unix/Type/_locales
@@ -0,0 +1,12 @@
+#compdef -value-,LANG,-default- -value-,LANGUAGE,-default- -P -value-,LC_*,-default-
+
+local expl locales
+
+if (( $+commands[locale] )); then
+  locales=( $(_call_program locales locale -a) )
+  [[ $OSTYPE = *-gnu ]] && locales=( ${locales/utf8/UTF-8} )
+else
+  locales=( /usr/lib/locale/*(:t) )
+fi
+
+_wanted locales expl locale compadd -a "$@" - locales
diff --git a/Completion/Unix/Type/_user_at_host b/Completion/Unix/Type/_user_at_host
new file mode 100644
index 000000000..a242ddeb6
--- /dev/null
+++ b/Completion/Unix/Type/_user_at_host
@@ -0,0 +1,31 @@
+#autoload
+
+# Complete user/host combinations. Normally this looks for the style
+# `users-hosts' for the tag `accounts'. A different tag may be given
+# with `-t tag'.
+# A `-' or `--' as the first argument is ignored.
+
+local expl suf tag=accounts
+
+if [[ "$1" = -t?* ]]; then
+  tag="${1[3,-1]}"
+  shift
+elif [[ "$1" = -t ]]; then
+  tag="$2"
+  shift 2
+fi
+
+[[ "$1" = -(|-) ]] && shift
+
+if [[ -prefix 1 *@ ]]; then
+  local user=${PREFIX%%@*}
+
+  compset -P 1 '*@'
+
+  _wanted -C user-at hosts expl "host for $user" \
+      _combination -s '[:@]' "${tag}" users-hosts users="$user" hosts "$@" -
+else
+  compset -S '@*' || suf="@"
+  _wanted users expl "user" \
+      _combination -s '[:@]' "${tag}" users-hosts users -S "$suf" -q "$@" -
+fi
diff --git a/Completion/X/Command/_netscape b/Completion/X/Command/_netscape
new file mode 100644
index 000000000..e1d02ae90
--- /dev/null
+++ b/Completion/X/Command/_netscape
@@ -0,0 +1,93 @@
+#compdef netscape
+
+local curcontext="$curcontext" state line expl ret=1 suf files
+typeset -A opt_args
+
+_x_arguments -C \
+  '-xrm:resource:_x_resource' \
+  '-help[show usage message]' \
+  '-version[show the version number and build date]' \
+  '-visual[use a specific server visual]:visual:_x_visual -b' \
+  '-install[install a private colormap]' \
+  '-no-install[use the default colormap]' \
+  '-ncols[max no. of colors to allocate for images]:n:' \
+  '-mono[force 1-bit-deep image display]' \
+  '-iconic[start up iconified]' \
+  '-remote[execute a command in an existing Netscape]:remote command:->remote' \
+  '-id[id of X window to send remote commands to]:window-id:' \
+  '-raise[raise window following remote command]' \
+  "-noraise[don't raise window following remote command]" \
+  '-nethelp[show nethelp]' \
+  -{dont-force-window-stacking,no-about-splash} \
+  -{,no-}{,irix-}session-management \
+  -{done-save,ignore}-geometry-prefs \
+  -{component-bar,composer,edit,messenger,mail,discussions,news} \
+  '*:location:->urls' && ret=0
+
+# Handle netscape remote commands
+if [[ "$state" = "remote" ]]; then  
+  local -a remote_commands
+  remote_commands=(openURL openFile saveAs mailto addBookmark)
+
+  compset -P '*\('
+  if compset -S '(|\\)\)*'; then
+    set - -S "" "$@"
+  else
+    set - -S"${${QIPREFIX:+)}:-\)}$compstate[quote] " "$@"
+  fi
+  case $IPREFIX in
+    openURL*|addBookmark*) state=urls;;
+    openFile*) _files "$@" -W ~;;
+    saveAs*) 
+      if compset -P "*,"; then
+        _wanted types expl 'data type' \
+            compadd "$@" -M 'm:{a-zA-Z}={A-Za-z}' HTML Text PostScript && ret=0
+      else
+        compset -S ",*" || suf=","
+        _files -qS "$suf" -W ~ && ret=0
+      fi
+    ;;
+    mailto*)
+      _email_addresses -s, -c && ret=0
+    ;;
+    *)
+      compset -S '(|\\)\(*' || suf="${${QIPREFIX:+(}:-\(}"
+      _wanted commands expl 'remote commands' \
+          compadd -qS "$suf" -M 'm:{a-zA-Z}={A-Za-z}' -a \
+                  remote_commands && ret=0
+    ;;
+  esac
+fi
+
+if [[ "$state" = "urls" ]]; then
+  _tags files urls
+  while _tags; do
+    _requested files expl 'file' _files "$@" && files=yes ret=0
+    if _requested urls; then
+      # Complete netscape urls
+      if compset -P about: ; then
+	_wanted values expl 'about what' \
+            compadd "$@" authors blank cache document fonts global hype \
+	    	image-cache license logo memory-cache mozilla plugins && ret=0
+      elif compset -P news: ; then
+	_newsgroups "$@" && ret=0
+      elif compset -P mailto: ; then
+        _email_addresses -c && ret=0
+      else
+	_tags prefixes
+	while _tags; do
+	  while _next_label prefixes expl 'URL prefix' "$@"; do
+            _urls "$expl[@]" && ret=0
+	    compset -S '[^:]*'
+            compadd -S '' "$expl[@]" about: news: mailto: mocha: javascript: && ret=0
+	  done
+	  (( ret )) || return 0
+	done
+        [[ -z "$files" ]] && _tags files
+      fi
+    fi
+    (( ret )) || return 0
+  done
+fi
+
+return ret
diff --git a/Completion/X/Type/_x_visual b/Completion/X/Type/_x_visual
new file mode 100644
index 000000000..b28208444
--- /dev/null
+++ b/Completion/X/Type/_x_visual
@@ -0,0 +1,10 @@
+#autoload
+
+local expl
+
+# with the -b option, include `Best' in the matches
+local best="${argv[(r)-b]:+Best}"
+argv[(i)-b]=()
+
+_wanted visuals expl visual compadd "$@" -M 'm:{a-zA-Z}={A-Za-z}' - \
+    $best DirectColor TrueColor PseudoColor StaticColor GrayScale StaticGray
diff --git a/Completion/Zsh/Command/_disable b/Completion/Zsh/Command/_disable
new file mode 100644
index 000000000..3b627fb5f
--- /dev/null
+++ b/Completion/Zsh/Command/_disable
@@ -0,0 +1,9 @@
+#compdef disable
+
+_arguments -C -s -A "-*" -S \
+  "(-f -r -s)-a[act on regular or global aliases]:*:regular or global aliases:(${(k)aliases} ${(k)galiases})" \
+  "(-a -r -s)-f[act on functions]:*:functions:(${(k)functions})" \
+  "(-a -f -s)-r[act on reserved words]:*:reserved-words:compadd -k reswords" \
+  "(-a -f -r)-s[act on suffix aliases]:*:suffix aliases:(${(k)saliases})" \
+  '-m[treat arguments as patterns]' \
+  "*:builtin command:(${(k)builtins})"
diff --git a/Completion/Zsh/Context/_equal b/Completion/Zsh/Context/_equal
new file mode 100644
index 000000000..a1577d62c
--- /dev/null
+++ b/Completion/Zsh/Context/_equal
@@ -0,0 +1,5 @@
+#compdef -equal-
+
+local expl
+
+_wanted commands expl command compadd -k commands