about summary refs log tree commit diff
path: root/Completion/Debian
diff options
context:
space:
mode:
authorClint Adams <clint@users.sourceforge.net>2005-11-25 15:17:18 +0000
committerClint Adams <clint@users.sourceforge.net>2005-11-25 15:17:18 +0000
commit59e1574eaae5bf95c28eb1f1eb7b9f76b9f4ef5a (patch)
treec6d294c3f61791e8697abcea975a770776b2a795 /Completion/Debian
parentd7db8f21d1ad60e71d98f2ccde51c1983fc858db (diff)
downloadzsh-59e1574eaae5bf95c28eb1f1eb7b9f76b9f4ef5a.tar.gz
zsh-59e1574eaae5bf95c28eb1f1eb7b9f76b9f4ef5a.tar.xz
zsh-59e1574eaae5bf95c28eb1f1eb7b9f76b9f4ef5a.zip
import dchroot, dlocate, dpkg-cross, madison, piuparts, toolchain-source,
bzr, cplay, date, quilt, urvt from HEAD
Diffstat (limited to 'Completion/Debian')
-rw-r--r--Completion/Debian/Command/_dchroot18
-rw-r--r--Completion/Debian/Command/_dlocate31
-rw-r--r--Completion/Debian/Command/_dpkg-cross22
-rw-r--r--Completion/Debian/Command/_madison14
-rw-r--r--Completion/Debian/Command/_piuparts30
-rw-r--r--Completion/Debian/Command/_toolchain-source9
6 files changed, 124 insertions, 0 deletions
diff --git a/Completion/Debian/Command/_dchroot b/Completion/Debian/Command/_dchroot
new file mode 100644
index 000000000..7a6973f1b
--- /dev/null
+++ b/Completion/Debian/Command/_dchroot
@@ -0,0 +1,18 @@
+#compdef dchroot
+
+local curcontext="$curcontext" state line expl ret=1
+
+_arguments -C \
+  '(-c -l -h -V)-a[execute in all known chroots]' \
+  '(-a -l -h -V)-c[execute in specified chroot]:chroot:->chroots' \
+  '(- *)-l[list available chroots]' \
+  '(-l)-d[preserve environment in chroot]' \
+  '(-h -l -V)-q[be quiet]' \
+  '(- *)-h[display help information]' \
+  '(- *)-V[display version information]' \
+  '*::args: _normal' && ret=0
+
+[[ -n $state ]] && _wanted chroots expl chroot \
+    compadd ${${$(dchroot -l)[3,-1]%,}:#\[*\]} && ret=0
+
+return ret
diff --git a/Completion/Debian/Command/_dlocate b/Completion/Debian/Command/_dlocate
new file mode 100644
index 000000000..f8333b222
--- /dev/null
+++ b/Completion/Debian/Command/_dlocate
@@ -0,0 +1,31 @@
+#compdef dlocate
+
+local context state line
+typeset -A opt_args
+
+_arguments \
+	'-h[help]' \
+	'-S[match strings only]' \
+	'-L[list all files in package]' \
+	'-l[almost-emulation of dpkg -l]' \
+	'-s[print status of package]' \
+	'-ls[ls -ldF of all files in package]' \
+	'-du[du -sck of all files in package]' \
+        '-conf[list conffiles in package]' \
+	'-lsconf[ls -ldF of conffiles in package]' \
+	'-md5sum[list md5sums (if any) of package]' \
+	'-md5check[check md5sums (if any) of package]' \
+	'-man[list man pages (if any) of package]' \
+	':arg:->stringorpkg' && return 0
+
+case "$state" in
+    (stringorpkg)
+      if (( $+opt_args[-S] )); then
+          _files
+      else
+          _alternative \
+		'string:search string:_files' \
+		'package:Debian packages:_deb_packages installed'
+      fi
+    ;;
+esac
diff --git a/Completion/Debian/Command/_dpkg-cross b/Completion/Debian/Command/_dpkg-cross
new file mode 100644
index 000000000..7d890827c
--- /dev/null
+++ b/Completion/Debian/Command/_dpkg-cross
@@ -0,0 +1,22 @@
+#compdef dpkg-cross
+
+local _dpkgcross_arches
+
+_dpkgcross_arches=(/etc/dpkg-cross/cross-config.*(N))
+_dpkgcross_arches=(${${_dpkgcross_arches#*.}:-alpha amd64 common cygwin-i386 gnu hppa i386 linux m32r m68k mips powerpc sh sh3 sh3eb sh4 sh4eb w32})
+
+_arguments \
+  '(-h --help)'{-h,--help}'[show summary of options]' \
+  '(-v --verbose)'{-v,--verbose}'[be more verbose]' \
+  '(-q --quiet)'{-q,--quiet}'[be more quiet]' \
+  '(-a --arch)'{-a,--arch}':architecture:('"$_dpkgcross_arches"')' \
+  '(-i --install)'{-i,--install}'[install packages]' \
+  '(-A --convert-anyway)'{-A,--convert-anyway}'[convert package even if not useful]' \
+  '(-b --build)'{-b,--build}'[just build but do not install]' \
+  '(-r --remove)'{-r,--remove}'[remove packages]' \
+  '(-s --status)'{-s,--status}'[print status of named packages]' \
+  '(-l --list)'{-l,--list}'[print short status of named packages or patterns]' \
+  '(-L --list-files)'{-L,--list-files}'[list files belonging to named packages]' \
+  '(-u --update)'{-u,--update}'[update current cross-inst]' \
+  '(-Q --query)'{-Q,--query}'[print available update packages]' \
+  '*:package or path or pattern:_files'
diff --git a/Completion/Debian/Command/_madison b/Completion/Debian/Command/_madison
new file mode 100644
index 000000000..ce3534a44
--- /dev/null
+++ b/Completion/Debian/Command/_madison
@@ -0,0 +1,14 @@
+#compdef madison
+
+_arguments \
+  '(-a --architecture)'{-a,--architecture=}':arch:_values -s , "architecture list" source all alpha arm hppa hurd-i386 i386 ia64 mips mipsel' \
+  '(-b --binary)'{-b,--binary-type=}':type:(deb udeb)' \
+  '(-c --component)'{-c,--component=}':component:_values -s , "component list" main contrib non-free' \
+  '(-g --greaterorequal)'{-g,--greaterorequal} \
+  '(-G --greaterthan)'{-G,--greaterthan} \
+  '(-h --help)'{-h,--help} \
+  '(-r --regex)'{-r,--regex} \
+  '(-s --suite)'{-s,--suite=}':suite:_values -s , "suite list" oldstable stable testing unstable' \
+  '(-S, --source-and-binary)'{-S,--source-and-binary} \
+  '*:package:_deb_packages avail'
+
diff --git a/Completion/Debian/Command/_piuparts b/Completion/Debian/Command/_piuparts
new file mode 100644
index 000000000..83e9ef115
--- /dev/null
+++ b/Completion/Debian/Command/_piuparts
@@ -0,0 +1,30 @@
+#compdef piuparts
+
+local context state line
+typeset -A opt_args
+
+_arguments -s \
+	'(-a --apt)'{-a,--apt} \
+	'(-b --basetgz)'{-b,--basetgz=}':base tarball:_files' \
+	'(-d --distribution)'{-d,--distribution=}':Debian distribution:(sarge etch sid experimental)' \
+	'(-i --ignore)*'{-i,--ignore=}':file to ignore:_files' \
+	'(-I --ignore-regexp)*'{-I,--ignore-regexp=}':expression to ignore' \
+	'(-k --keep-tmpdir)'{-k,--keep-tmpdir} \
+	'(-l --log-file)'{-l,--logfile=}':log file:_files' \
+	'(-m --mirror)'{-m,--mirror=}':Debian mirror:_urls' \
+	'(-n --no-ignores)'{-n,--no-ignores} \
+	'(-p --pbuilder)'{-p,--pbuilder}'[use /var/cache/pbuilder/base.tgz]' \
+	'(-s --save)'{-s,--save=}':target tarball:_files' \
+	'(-t --tmpdir)'{-t,--tmpdir=}':temp dir:_files -/' \
+	'-V[version]' \
+	'*:package:->packages' && return 0
+
+case "$state" in
+    (packages)
+      if (( $+opt_args[-a] )); then
+          _deb_packages avail
+      else
+          _files -g '*.deb'
+      fi
+    ;;
+esac
diff --git a/Completion/Debian/Command/_toolchain-source b/Completion/Debian/Command/_toolchain-source
new file mode 100644
index 000000000..25dd83df8
--- /dev/null
+++ b/Completion/Debian/Command/_toolchain-source
@@ -0,0 +1,9 @@
+#compdef tpkg-install tpkg-make tpkg-debarch tpkg-update tpkg-install-libc
+
+local expl
+
+(( CURRENT == 2 )) &&
+_wanted target expl 'target platform' \
+   compadd alpha-linux arm-linux hppa-linux i{3..6}86-linux ia32-linux ia64-linux m68k-linux \
+           mipsel-linux mips-linux ppc-linux powerpc-linux sparc-linux s390-linux
+