Mercurial > dotfiles
comparison .zfun/_hg @ 270:1e2125a577da
_hg: import updated version from upstream
| author | Augie Fackler <durin42@gmail.com> |
|---|---|
| date | Mon, 12 Dec 2011 11:47:26 -0600 |
| parents | c451e42b3ecc |
| children | 268587bbfc2b |
comparison
equal
deleted
inserted
replaced
| 269:546ac96796da | 270:1e2125a577da |
|---|---|
| 163 } | 163 } |
| 164 | 164 |
| 165 _hg_labels() { | 165 _hg_labels() { |
| 166 _hg_tags "$@" | 166 _hg_tags "$@" |
| 167 _hg_bookmarks "$@" | 167 _hg_bookmarks "$@" |
| 168 _hg_branches "$@" | |
| 168 } | 169 } |
| 169 | 170 |
| 170 _hg_tags() { | 171 _hg_tags() { |
| 171 typeset -a tags | 172 typeset -a tags |
| 172 local tag rev | 173 local tag rev |
| 187 then | 188 then |
| 188 bookmarks+=($bookmark[-2]) | 189 bookmarks+=($bookmark[-2]) |
| 189 fi | 190 fi |
| 190 done | 191 done |
| 191 (( $#bookmarks )) && _describe -t bookmarks 'bookmarks' bookmarks | 192 (( $#bookmarks )) && _describe -t bookmarks 'bookmarks' bookmarks |
| 193 } | |
| 194 | |
| 195 _hg_branches() { | |
| 196 typeset -a branches | |
| 197 local branch | |
| 198 | |
| 199 _hg_cmd branches | while read branch | |
| 200 do | |
| 201 branches+=(${branch/ # [0-9]#:*}) | |
| 202 done | |
| 203 (( $#branches )) && _describe -t branches 'branches' branches | |
| 192 } | 204 } |
| 193 | 205 |
| 194 # likely merge candidates | 206 # likely merge candidates |
| 195 _hg_mergerevs() { | 207 _hg_mergerevs() { |
| 196 typeset -a heads | 208 typeset -a heads |
| 358 '*--config[set/override config option]:defined config items:_hg_config' | 370 '*--config[set/override config option]:defined config items:_hg_config' |
| 359 '(--quiet -q)'{-q,--quiet}'[suppress output]' | 371 '(--quiet -q)'{-q,--quiet}'[suppress output]' |
| 360 '(--help -h)'{-h,--help}'[display help and exit]' | 372 '(--help -h)'{-h,--help}'[display help and exit]' |
| 361 '--debug[debug mode]' | 373 '--debug[debug mode]' |
| 362 '--debugger[start debugger]' | 374 '--debugger[start debugger]' |
| 363 '--encoding[set the charset encoding (default: UTF8)]' | 375 '--encoding[set the charset encoding]' |
| 364 '--encodingmode[set the charset encoding mode (default: strict)]' | 376 '--encodingmode[set the charset encoding mode]' |
| 365 '--lsprof[print improved command execution profile]' | 377 '--lsprof[print improved command execution profile]' |
| 366 '--traceback[print traceback on exception]' | 378 '--traceback[print traceback on exception]' |
| 367 '--time[time how long the command takes]' | 379 '--time[time how long the command takes]' |
| 368 '--profile[profile]' | 380 '--profile[profile]' |
| 369 '--version[output version information and exit]' | 381 '--version[output version information and exit]' |
| 615 '*'{-r,--rev}'[show the specified revision or range]:revision:_hg_revrange' \ | 627 '*'{-r,--rev}'[show the specified revision or range]:revision:_hg_revrange' \ |
| 616 '(--no-merges -M)'{-M,--no-merges}'[do not show merges]' \ | 628 '(--no-merges -M)'{-M,--no-merges}'[do not show merges]' \ |
| 617 '(--only-merges -m)'{-m,--only-merges}'[show only merges]' \ | 629 '(--only-merges -m)'{-m,--only-merges}'[show only merges]' \ |
| 618 '(--patch -p)'{-p,--patch}'[show patch]' \ | 630 '(--patch -p)'{-p,--patch}'[show patch]' \ |
| 619 '(--prune -P)'{-P+,--prune}'[do not display revision or any of its ancestors]:revision:_hg_labels' \ | 631 '(--prune -P)'{-P+,--prune}'[do not display revision or any of its ancestors]:revision:_hg_labels' \ |
| 632 '(--branch -b)'{-b+,--branch}'[show changesets within the given named branch]:branch:_hg_branches' \ | |
| 620 '*:files:_hg_files' | 633 '*:files:_hg_files' |
| 621 } | 634 } |
| 622 | 635 |
| 623 _hg_cmd_manifest() { | 636 _hg_cmd_manifest() { |
| 624 _arguments -s -w : $_hg_global_opts \ | 637 _arguments -s -w : $_hg_global_opts \ |
