Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: new _ttyctl, _ulimit and _vared
- X-seq: zsh-workers 13898
- From: Oliver Kiddle <opk@xxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: PATCH: new _ttyctl, _ulimit and _vared
- Date: Tue, 03 Apr 2001 21:08:06 +0100
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- Sender: opk
As promised, here are completions for a couple more builtins and
what I think we agreed _vared should be. Hopefully the _vared here
is right?
Oliver
Index: Completion/Zsh/Command/.distfiles
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Zsh/Command/.distfiles,v
retrieving revision 1.2
diff -u -r1.2 .distfiles
--- Completion/Zsh/Command/.distfiles 2001/04/02 13:04:05 1.2
+++ Completion/Zsh/Command/.distfiles 2001/04/03 21:06:25
@@ -6,4 +6,5 @@
_cd _enable _print _source _wait _zmodload
_command _fc _prompt _stat _which _zpty
_compdef _hash _read _trap _zcompile _zstyle
+_ttyctl _ulimit _vared
'
Index: Completion/Zsh/Command/_ttyctl
===================================================================
RCS file: _ttyctl
diff -N _ttyctl
--- /dev/null Mon Dec 11 17:26:27 2000
+++ _ttyctl Tue Apr 3 14:06:25 2001
@@ -0,0 +1,4 @@
+#compdef ttyctl
+
+_arguments '(-u)-f[freeze terminal settings]' \
+ '(-f)-u[unfreeze terminal settings]'
Index: Completion/Zsh/Command/_ulimit
===================================================================
RCS file: _ulimit
diff -N _ulimit
--- /dev/null Mon Dec 11 17:26:27 2000
+++ _ulimit Tue Apr 3 14:06:25 2001
@@ -0,0 +1,17 @@
+#compdef ulimit
+
+[[ $PREFIX = u* ]] && compadd unlimited && return 0
+
+_arguments -s \
+ '-H[set hard limits]' \
+ '-S[set soft and hard limits (with -H)]' \
+ '(-H -S -c -d -f -l -m -n -s -t *)-a[list all current resource limits]' \
+ '-c[core dump size limit]:max core dump size (512-byte blocks)' \
+ '-d[maximum size of data segment]:maximum size of data segment (K-bytes)' \
+ '-f[size of largest file allowed]:size of largest file allowed (512-byte blocks)' \
+ '-l[maximum size of locked in memory]:maximum size of locked in memory (K-bytes)' \
+ '-m[maximum size of physical memory]:maximum size of physical memory (K-bytes)' \
+ '-n[maximum no. of open file descriptors]:maximum no. of open file descriptors' \
+ '-s[stack size limit]:stack size limit (K-bytes)' \
+ '-t[maximum cpu time per process]:maximum cpu time per process (seconds)' \
+ '*:size of largest file allowed'
Index: Completion/Zsh/Command/_vared
===================================================================
RCS file: _vared
diff -N _vared
--- /dev/null Mon Dec 11 17:26:27 2000
+++ _vared Tue Apr 3 14:06:25 2001
@@ -0,0 +1,12 @@
+#compdef vared
+
+_arguments -s -A "-*" \
+ '(-a)-A[edit associative array]' \
+ '(-A)-a[edit array parameter]' \
+ "-c[create parameter or change type]" \
+ '-p+[specify left prompt]:prompt' \
+ '-r+[specify right prompt]:right prompt' \
+ '-h[allow access to history]' \
+ '-e[exit on EOF (^D)]' \
+ '1:parameter spec:_vars'
+
Index: Completion/Zsh/Type/_vars
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Zsh/Type/_vars,v
retrieving revision 1.1
diff -u -r1.1 _vars
--- Completion/Zsh/Type/_vars 2001/04/02 11:19:13 1.1
+++ Completion/Zsh/Type/_vars 2001/04/03 21:06:27
@@ -1,4 +1,4 @@
-#compdef getopts unset vared
+#compdef getopts unset
# This will handle completion of keys of associative arrays, e.g. at
# `vared foo[<TAB>'.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author