about summary refs log tree commit diff
path: root/Completion/Cvs/_cvs_modules
diff options
context:
space:
mode:
authorTanaka Akira <akr@users.sourceforge.net>1999-08-26 11:07:42 +0000
committerTanaka Akira <akr@users.sourceforge.net>1999-08-26 11:07:42 +0000
commitf77d7a9123b6169803d3379905c015cf0cb8cb49 (patch)
treee91558e3e8615f66228f110ea610024d16da65d2 /Completion/Cvs/_cvs_modules
parent9b20f822d01a0c33e6321deb42d6d59e818d6c5a (diff)
downloadzsh-f77d7a9123b6169803d3379905c015cf0cb8cb49.tar.gz
zsh-f77d7a9123b6169803d3379905c015cf0cb8cb49.tar.xz
zsh-f77d7a9123b6169803d3379905c015cf0cb8cb49.zip
zsh-workers/7495
Diffstat (limited to 'Completion/Cvs/_cvs_modules')
-rw-r--r--Completion/Cvs/_cvs_modules12
1 files changed, 12 insertions, 0 deletions
diff --git a/Completion/Cvs/_cvs_modules b/Completion/Cvs/_cvs_modules
new file mode 100644
index 000000000..f662f8a6e
--- /dev/null
+++ b/Completion/Cvs/_cvs_modules
@@ -0,0 +1,12 @@
+#autoload
+
+local root=$CVSROOT
+[[ -f CVS/Root ]] && root=$(<CVS/Root)
+
+if [[ $root = :* || ! -d $root ]]; then
+  _message "module name"
+else
+  compadd - \
+    $root/^CVSROOT(:t) \
+    ${${(M)${(f)"$(<$root/CVSROOT/modules)"}:#[^#]*}%%[ 	]*}
+fi