about summary refs log tree commit diff
path: root/Completion/Unix
diff options
context:
space:
mode:
authorPaul Ackersviller <packersv@users.sourceforge.net>2007-11-13 01:38:56 +0000
committerPaul Ackersviller <packersv@users.sourceforge.net>2007-11-13 01:38:56 +0000
commit5d90cfe1d2aa7474d3c0eceb9cb97ec473a53230 (patch)
tree768a755730bf12640e5f92db86e3fa0cdf8126bc /Completion/Unix
parentd0baf75be8a6b819fd7a14ba8a574d9057756f64 (diff)
downloadzsh-5d90cfe1d2aa7474d3c0eceb9cb97ec473a53230.tar.gz
zsh-5d90cfe1d2aa7474d3c0eceb9cb97ec473a53230.tar.xz
zsh-5d90cfe1d2aa7474d3c0eceb9cb97ec473a53230.zip
Merge of 23226 : "nice -n<->" wasn't handled.
Diffstat (limited to 'Completion/Unix')
-rw-r--r--Completion/Unix/Command/_nice14
1 files changed, 14 insertions, 0 deletions
diff --git a/Completion/Unix/Command/_nice b/Completion/Unix/Command/_nice
new file mode 100644
index 000000000..29070697f
--- /dev/null
+++ b/Completion/Unix/Command/_nice
@@ -0,0 +1,14 @@
+#compdef nice
+
+shift words
+(( CURRENT-- ))
+
+if [[ $CURRENT -gt 1 && $words[1] = ([-+](-|)|-n)<-> ]]; then
+    shift words
+    (( CURRENT -- ))
+elif [[ $CURRENT -gt 2 && $words[1] = -n ]]; then
+    shift 2 words
+    (( CURRENT -= 2 ))
+fi
+
+_normal