Skip navigation

Tag Archives: branch

I finally got tired of manually typing out all of the characters in the branch names that JIRA was creating for my projects on the M1 Macbook Pro that work has provided for me.

Solution is really simple and I’m kicking myself for not having done it earlier now.

Inside a Zshell terminal, type the following two lines:

echo 'autoload -Uz compinit && compinit' >> ~/.zshrc
source ~/.zshrc

That will enable tab autocomplete and reload the shell so the change takes effect immediately.

Source

I’ve been using command-line git for about a year now. I recently decided to tackle my problem of not knowing how to delete remote branches.

I’ve pushed quite a few branches to some remote repos as a means of transporting projects to/from home/work. As a result there are quite a few useless branches in most of my git projects and it makes working with

git branch -a

more cumbersome than it need be.

In searching for an answer, I actually found out that it is much simpler than I had anticipated. Very similar to what I was already doing to push the branch to the remote repo.

git push origin :<branchname>

That’s it! I just have to add a colon to the remote branch name and git deletes it. Not at all intuitive, but very easy to remember.

%d bloggers like this: