mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-25 17:41:19 +02:00
21913: completion for ping.
This commit is contained in:
parent
6d4c633119
commit
6f8d328a53
2 changed files with 66 additions and 0 deletions
|
@ -3,6 +3,9 @@
|
||||||
* 21912: Src/Modules/cap.c: silence unused parameter
|
* 21912: Src/Modules/cap.c: silence unused parameter
|
||||||
compile warnings.
|
compile warnings.
|
||||||
|
|
||||||
|
* 21913: Completion/Unix/Command/_ping: completion
|
||||||
|
for ping.
|
||||||
|
|
||||||
2005-10-23 Bart Schaefer <schaefer@zsh.org>
|
2005-10-23 Bart Schaefer <schaefer@zsh.org>
|
||||||
|
|
||||||
* unposted: Src/prompt.c: fix --disable-multibyte compile error
|
* unposted: Src/prompt.c: fix --disable-multibyte compile error
|
||||||
|
|
63
Completion/Unix/Command/_ping
Normal file
63
Completion/Unix/Command/_ping
Normal file
|
@ -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
|
Loading…
Reference in a new issue