Enabling the auto-complete feature in Git with Z-shell
May 30th, 2020
- Link to Enabling the auto-complete feature in Git with Z-shell podcast on anchorfm
Not only can you
auto-complete command line
Zsh, for example, but you can auto-complete commands in
Git as well! And it is quite simple.
First, go to the
Git repository on
Github and to the following link:
There, you will see a number of files for different
Git shell environments.
Prompt (for Windows), to name a couple. I use
Zsh, so I downloaded the
git-completion.zsh file to my desktop and then moved it into my
~ (Home) directory. After that, I added the following to my
.zshrc file (also located in my home directory):
I placed this line right above my
I made sure to quit
Terminal and then open a new
Terminal window instance before testing out my new
Git auto-complete feature. And it works! For example, if I type
che followed by the
tab key, I get the following in
There are other ways of getting the
git-completion.zsh file onto your desktop from Github such as with
git pull, but I will get into that in another podcast (post).
I will be embedding this episode of Plugging in The Holes along with a transcript in the form of a post on interglobalmedianetwork.com for your hearing and reading pleasure. Bye for now!