Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

git rev-parse --short HEAD

#It helps you to find out the commit ID of the current HEAD
git rev-parse HEAD
#OR if you want the shorter commit
git rev-parse --short HEAD
#If you find the latest commit of another branch, you can do
git rev-parse <local-branch-name>
git rev-parse origin/<remote-branch-name>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #git #HEAD
ADD COMMENT
Topic
Name
3+6 =