about summary refs log tree commit diff
path: root/Completion/Unix
diff options
context:
space:
mode:
authorClint Adams <clint@users.sourceforge.net>2005-10-24 02:34:20 +0000
committerClint Adams <clint@users.sourceforge.net>2005-10-24 02:34:20 +0000
commit6f8d328a53bc2c4965b36e36400d1c5e7b4635dd (patch)
treee97644b1cd24b48efd5a6049b35a00bdc8f30518 /Completion/Unix
parent6d4c63311954fc930881e388c8dedb39fde6e139 (diff)
downloadzsh-6f8d328a53bc2c4965b36e36400d1c5e7b4635dd.tar.gz
zsh-6f8d328a53bc2c4965b36e36400d1c5e7b4635dd.tar.xz
zsh-6f8d328a53bc2c4965b36e36400d1c5e7b4635dd.zip
21913: completion for ping.
Diffstat (limited to 'Completion/Unix')
-rw-r--r--Completion/Unix/Command/_ping63
1 files changed, 63 insertions, 0 deletions
diff --git a/Completion/Unix/Command/_ping b/Completion/Unix/Command/_ping
new file mode 100644
index 000000000..e59f6fa9f
--- /dev/null
+++ b/Completion/Unix/Command/_ping
@@ -0,0 +1,63 @@
+#compdef ping
+
+if _pick_variant iputils=iputils unix -V; then
+              
+  _arguments \
+    '-a[audible]' \
+    '-A[adaptive]' \
+    '-b[allow pinging a broadcast address]' \
+    '-B[do not allow ping to change source address]' \
+    '-c:count' \
+    '-d[set SO_DEBUG on the socket]' \
+    '-f[flood ping]' \
+    '-i:interval in seconds' \
+    '-I:iface:_net_interfaces' \
+    '-l:preload number' \
+    '-L[suppress loopback of multicast packets]' \
+    '-n[numeric output only]' \
+    '-p:padding pattern' \
+    '-Q:QoS TOS bits' \
+    '-q[quiet]' \
+    '-r[bypass normal routing tables]' \
+    '-R[record route]' \
+    '-s:packet size in bytes' \
+    '-S:sndbuf' \
+    '-t:timeout in seconds' \
+    '-T:timestamp option:(tsonly tsandaddr tsprespec)' \
+    '-M:Path MTU Discovery strategy:((do\:prohibit\ fragmentation want\:fragment\ locally dont\:do\ not\ set\ DF\ flag))' \
+    '-U[print full user-to-user latency]' \
+    '-v[verbose]' \
+    '-w:deadline in seconds' \
+    '-W:seconds to wait for a response' \
+    ':host:_hosts'
+
+else
+
+# FreeBSD 4.11
+
+  _arguments \
+    '-A[audible for no packet]' \
+    '-Q[somewhat quiet]' \
+    '-R[record route]' \
+    '-a[audible for each packet]' \
+    '-d[set SO_DEBUG on the socket]' \
+    '-f[flood ping]' \
+    '-n[numeric output only]' \
+    '-q[quiet]' \
+    '-r[bypass normal routing tables]' \
+    '-v[verbose]' \
+    '-c:count' \
+    '-i:wait seconds' \
+    '-l:preload number' \
+    '-m:ttl' \
+    '-p:padding pattern' \
+    '-P:IPsec policy' \
+    '-s:packet size in bytes' \
+    '-S:src addr' \
+    '-t:timeout in seconds' \
+    '-L[suppress loopback of multicast packets]' \
+    '-I:iface:_net_interfaces' \
+    '-T:ttl for multicasted packets' \
+    ':host:_hosts'
+
+fi