1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-08 12:01:21 +02:00

19939: hg committable files

This commit is contained in:
Andrew Magee 2014-06-04 17:03:41 +10:00 committed by Peter Stephenson
parent 32756f78af
commit 605cc1ba57
2 changed files with 16 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2014-06-06 Peter Stephenson <p.w.stephenson@ntlworld.com>
* Andrew Magee: 32698: Completion/Unix/Command/_hg: show
committable files.
2014-06-05 Barton E. Schaefer <schaefer@zsh.org>
* 32723: Src/glob.c: add braces around some if/else branches

View file

@ -226,6 +226,16 @@ _hg_modified() {
_wanted files expl 'modified files' _multi_parts / status_files
}
_hg_committable() {
typeset -a status_files
# A file is a candidate for `hg commit` if it is:
# - modified (m), or
# - added (a), or
# - removed (r)
_hg_status mar
_wanted files expl 'committable files' _multi_parts / status_files
}
_hg_resolve() {
local rstate rpath
@ -476,7 +486,7 @@ _hg_cmd_commit() {
'(--logfile -l)'{-l+,--logfile}'[read commit message from specified file]:log file:_files' \
'(--date -d)'{-d+,--date}'[record datecode as commit date]:date code:' \
'(--user -u)'{-u+,--user}'[record user as commiter]:user:' \
'*:file:_hg_files'
'*:file:_hg_committable'
}
_hg_cmd_copy() {