Import gitrc.sh
file into ~/.zshrc
:
# ~/.zshrc
source ~/gitrc.sh
You'll then get access to the commands bellow.
# show status
s
# show one line log with pretty formatting
l
# show detailed log
lll
# show branches
b
# delete <branch>
d <branch>
# delete current branch and check out `master`
d
# check out <branch> if it exists, otherwise create new branch and check it out
c <branch>
# check out `master`
c
# check out <remote_branch>
cc <remote_branch>
# commit the files in stating. If no files in stating then commit all changes in the working directory
cm "<commit_message>"
# If no message provided, then amend the previous commit and keep the same message
cm
# git force push. If it doesn't track a remote branch then set one up automatically.
p
# git reset --hard HEAD
rrr