From 1f5ef83f0f3aea0597ef3db7a05970420646bfdc Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Wed, 5 Sep 2012 14:54:39 +0000 Subject: Jun T.: 30658: complete more uniq options --- Completion/Unix/Command/_uniq | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Completion') diff --git a/Completion/Unix/Command/_uniq b/Completion/Unix/Command/_uniq index be58fd775..dcd7a6f49 100644 --- a/Completion/Unix/Command/_uniq +++ b/Completion/Unix/Command/_uniq @@ -13,12 +13,17 @@ args=( '(-u --unique)'{-u,--unique}'[only print unique lines]' '(-w --check-chars)'{-w,--check-chars=}'[specify maximum number of characters to compare]:characters' '(-W --check-fields)'{-W,--check-fields=}'[specify maximum number of fields to compare]:fields' + '(-z --zero-terminated)'{-z,--zero-terminated}'[delimit lines with null character, not newline]' '(- *)--help[display help information]' '(- *)--version[display version information]' ) if ! _pick_variant gnu=Free\ Soft unix --version; then - args=( ${(M)args:#(|\*)(|\(*\))-[cdufs]*} ) + local optchars="cdufs" + if [[ "$OSTYPE" == (darwin|freebsd)* ]]; then + optchars="${optchars}i" + fi + args=( ${(M)args:#(|\*)(|\(*\))-[$optchars]*} ) fi _arguments "$args[@]" \ -- cgit 1.4.1