diff options
author | Peter Stephenson <pws@users.sourceforge.net> | 2003-08-21 18:27:15 +0000 |
---|---|---|
committer | Peter Stephenson <pws@users.sourceforge.net> | 2003-08-21 18:27:15 +0000 |
commit | 6bbad942fe9c57ea61655faf583c48898a7bed2d (patch) | |
tree | d61f6b46976420a79717a650424b83f18961ff3f | |
parent | d27da0dce045169cc7d5780a2a8a9365836cda38 (diff) | |
download | zsh-6bbad942fe9c57ea61655faf583c48898a7bed2d.tar.gz zsh-6bbad942fe9c57ea61655faf583c48898a7bed2d.tar.xz zsh-6bbad942fe9c57ea61655faf583c48898a7bed2d.zip |
18958: improved option handling for p4 change
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | Completion/Unix/Command/_perforce | 8 |
2 files changed, 11 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog index 4b42b815c..158da09c5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2003-08-21 Peter Stephenson <pws@csr.com> + + * 18958: Completion/Unix/Command/_perforce: improved option + handling for p4 change. + 2003-08-21 Oliver Kiddle <opk@zsh.org> * 18956: Completion/Unix/Command/_a2ps: update for a2ps 4.13 diff --git a/Completion/Unix/Command/_perforce b/Completion/Unix/Command/_perforce index 6803ad6da..afadda4af 100644 --- a/Completion/Unix/Command/_perforce +++ b/Completion/Unix/Command/_perforce @@ -1173,13 +1173,17 @@ _perforce_cmd_branches() { (( $+functions[_perforce_cmd_change] )) || _perforce_cmd_change() { + local ctype + # Unless forcing or outputting, we don't + # complete committed changes since they can't be altered. + [[ ${words[(I)-*(f|o)*]} -eq 0 ]] && ctype=" -tp" _arguments -s : \ '(-o)-f[allow force by superuser]' \ '-s[joblist includes the fix status]' \ - '(-o -i)-d[describe newly created pending change]' \ + '(-o -i)-d[discard newly created pending change]' \ '(-d -i -f)-o[output specification to standard output]' \ '(-d -o)-i[read specification from standard input]' \ - '(-i)1::change:_perforce_changes -tp' + "(-i)1::change:_perforce_changes$ctype" } |