In this tutorial, we’ll discuss 7 Git Commands/Concepts You May Do Not Know Yet

1. multiple git commands separated by ; (semi-colon)

You can use multiple Git commands separated by ; (semi-colon)

$ git --version; git branch // separated by semi-colon

Image for post

2. alias git commands

You can make the commands alias for reusability

Let’s alias git remote -v (a command to check the remote origin) as show-origin

$ git config --global alias.show-origin 'remote -v'
$ git show-origin

Image for post

Let’s alias git log --graph --pretty=oneline (a command to print commit logs) as show-graph

$ git config --global alias.show-graph 'log --graph --pretty=oneline'
$ git show-graph

Image for post

#programming #git #javascript #web-development #technology

7 Git Commands/Concepts You May Do Not Know Yet
17.50 GEEK