Skip to content

Commit 4a5856c

Browse files
szedergitster
authored andcommitted
bash: update 'git svn' options
'git svn' got some new subcommands and otions in the last couple of months. This patch adds completion support for them. In particular: * 'fetch', 'clone', etc.: '--ignore-paths=' * 'init' and 'clone': '--prefix=', '--use-log-author', '--add-author-from' * 'dcommit': '--commit-url', '--revision' * 'log': '--color' * 'rebase': '--dry-run' * 'branch', 'tag', 'blame', 'migrate' subcommands and their options Signed-off-by: SZEDER Gábor <[email protected]> Acked-by: Shawn O. Pearce <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent d532ebd commit 4a5856c

File tree

1 file changed

+25
-6
lines changed

1 file changed

+25
-6
lines changed

contrib/completion/git-completion.bash

Lines changed: 25 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1600,7 +1600,8 @@ _git_svn ()
16001600
local subcommands="
16011601
init fetch clone rebase dcommit log find-rev
16021602
set-tree commit-diff info create-ignore propget
1603-
proplist show-ignore show-externals
1603+
proplist show-ignore show-externals branch tag blame
1604+
migrate
16041605
"
16051606
local subcommand="$(__git_find_subcommand "$subcommands")"
16061607
if [ -z "$subcommand" ]; then
@@ -1611,13 +1612,15 @@ _git_svn ()
16111612
--follow-parent --authors-file= --repack=
16121613
--no-metadata --use-svm-props --use-svnsync-props
16131614
--log-window-size= --no-checkout --quiet
1614-
--repack-flags --use-log-author --localtime $remote_opts
1615+
--repack-flags --use-log-author --localtime
1616+
--ignore-paths= $remote_opts
16151617
"
16161618
local init_opts="
16171619
--template= --shared= --trunk= --tags=
16181620
--branches= --stdlayout --minimize-url
16191621
--no-metadata --use-svm-props --use-svnsync-props
1620-
--rewrite-root= $remote_opts
1622+
--rewrite-root= --prefix= --use-log-author
1623+
--add-author-from $remote_opts
16211624
"
16221625
local cmt_opts="
16231626
--edit --rmdir --find-copies-harder --copy-similarity=
@@ -1637,7 +1640,8 @@ _git_svn ()
16371640
dcommit,--*)
16381641
__gitcomp "
16391642
--merge --strategy= --verbose --dry-run
1640-
--fetch-all --no-rebase $cmt_opts $fc_opts
1643+
--fetch-all --no-rebase --commit-url
1644+
--revision $cmt_opts $fc_opts
16411645
"
16421646
;;
16431647
set-tree,--*)
@@ -1651,13 +1655,13 @@ _git_svn ()
16511655
__gitcomp "
16521656
--limit= --revision= --verbose --incremental
16531657
--oneline --show-commit --non-recursive
1654-
--authors-file=
1658+
--authors-file= --color
16551659
"
16561660
;;
16571661
rebase,--*)
16581662
__gitcomp "
16591663
--merge --verbose --strategy= --local
1660-
--fetch-all $fc_opts
1664+
--fetch-all --dry-run $fc_opts
16611665
"
16621666
;;
16631667
commit-diff,--*)
@@ -1666,6 +1670,21 @@ _git_svn ()
16661670
info,--*)
16671671
__gitcomp "--url"
16681672
;;
1673+
branch,--*)
1674+
__gitcomp "--dry-run --message --tag"
1675+
;;
1676+
tag,--*)
1677+
__gitcomp "--dry-run --message"
1678+
;;
1679+
blame,--*)
1680+
__gitcomp "--git-format"
1681+
;;
1682+
migrate,--*)
1683+
__gitcomp "
1684+
--config-dir= --ignore-paths= --minimize
1685+
--no-auth-cache --username=
1686+
"
1687+
;;
16691688
*)
16701689
COMPREPLY=()
16711690
;;

0 commit comments

Comments
 (0)