File tree 1 file changed +16
-6
lines changed
1 file changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -61,13 +61,14 @@ Check if your current completion rules autocomplete `git` after installing
61
61
the wrapper script. Try ` git checko ` + <kbd >TAB</kbd >
62
62
63
63
If your git commands are no longer autocompleted, install
64
- [ my modified fork of complete_alias] ( https://github.com/lu0 /complete-alias ) .
64
+ [ complete_alias@3fc67e8 ] ( https://github.com/cykerway /complete-alias/tree/3fc67e8 ) .
65
65
66
66
``` sh
67
67
sudo apt install bash-completion
68
- git clone https://github.com/lu0/complete-alias
69
- cd complete-alias/
70
- echo " . $PWD /complete_alias" >> ~ /.bash_completion
68
+ git clone https://github.com/cykerway/complete-alias ~ /.complete-alias
69
+ cd ~ /.complete-alias
70
+ git checkout 3fc67e8
71
+ echo " . ${PWD} /complete_alias" >> ~ /.bash_completion
71
72
```
72
73
73
74
Inherit ` git ` 's completion rules by pasting the following in your ` ~/.bashrc ` or
@@ -76,8 +77,17 @@ Inherit `git`'s completion rules by pasting the following in your `~/.bashrc` or
76
77
``` sh
77
78
alias git=" source git-worktree-wrapper"
78
79
complete -F _complete_alias git
79
- _complete_alias_overrides () {
80
- echo git git
80
+
81
+ __compal__get_alias_body () {
82
+ local cmd=" $1 "
83
+ local body; body=" $( alias " $cmd " ) "
84
+
85
+ # Overrides
86
+ case " $cmd " in
87
+ " git" ) body=" git"
88
+ esac
89
+
90
+ echo " ${body#* =} " | command xargs
81
91
}
82
92
` ` `
83
93
You can’t perform that action at this time.
0 commit comments