Working with git can be hard, verbose, and repetitive. I’ve been using this small collection of bash/zsh functions for a few years now and I don’t think I could work without them anymore.
main- quickly jump back to the default/
HEADbranch of your repo without needing to know what the name of that branch is.
rebase- rebase your current branch against the current state of the default/
HEADbranch as it is on the remote server.
rmbranch- delete your current working branch and move to the default/
HEADbranch. Great for PR cleanup!