File tree Expand file tree Collapse file tree 2 files changed +18
-6
lines changed Expand file tree Collapse file tree 2 files changed +18
-6
lines changed Original file line number Diff line number Diff line change @@ -2597,7 +2597,7 @@ _git_whatchanged ()
2597
2597
_git_log
2598
2598
}
2599
2599
2600
- _git ()
2600
+ _main_git ()
2601
2601
{
2602
2602
local i c=1 command __git_dir
2603
2603
@@ -2648,7 +2648,7 @@ _git ()
2648
2648
fi
2649
2649
}
2650
2650
2651
- _gitk ()
2651
+ _main_gitk ()
2652
2652
{
2653
2653
__git_has_doubledash && return
2654
2654
@@ -2700,13 +2700,25 @@ __git_complete ()
2700
2700
|| complete -o default -o nospace -F $wrapper $1
2701
2701
}
2702
2702
2703
- __git_complete git _git
2704
- __git_complete gitk _gitk
2703
+ # wrapper for backwards compatibility
2704
+ _git ()
2705
+ {
2706
+ __git_wrap_main_git
2707
+ }
2708
+
2709
+ # wrapper for backwards compatibility
2710
+ _gitk ()
2711
+ {
2712
+ __git_wrap_main_gitk
2713
+ }
2714
+
2715
+ __git_complete git _main_git
2716
+ __git_complete gitk _main_gitk
2705
2717
2706
2718
# The following are necessary only for Cygwin, and only are needed
2707
2719
# when the user has tab-completed the executable name and consequently
2708
2720
# included the '.exe' suffix.
2709
2721
#
2710
2722
if [ Cygwin = " $( uname -o 2> /dev/null) " ]; then
2711
- __git_complete git.exe _git
2723
+ __git_complete git.exe _main_git
2712
2724
fi
Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ run_completion ()
63
63
local _cword
64
64
_words=( $1 )
65
65
(( _cword = ${# _words[@]} - 1 ))
66
- __git_wrap_git && print_comp
66
+ __git_wrap_main_git && print_comp
67
67
}
68
68
69
69
test_completion ()
You can’t perform that action at this time.
0 commit comments