Undo the last commit

As a software engineer or developer, I am pretty sure we often use git in our work on a daily basis. Many commits are committed to your local or remote…

Create or update a commit by a specified author

Use git commit -m <message> to create a new commit with the specified <message>. Use the –author option to change the <name> and <email> of the commit’s author. git commit -m <message> –author=”<name> <email>” # Make some changes to…

Create an empty commit

We use VCS as the back-end technology to track changes made on each submission or dataset into our system. The users or submitters can update their submissions and all changes…

Add git branch name to bash prompt

By default, git won’t display branch name to terminal prompt. To know which branch you are in, just run git branch command. However, if you want to customise how to…