What is a hash in Git?

Experience Level: Junior
Tags: GitSource control

Answer

In Git, each commit has 40 character identifier that is calculated using SHA-1 hashing algorithm. This commit identifier is called hash.

When you execute git log command, you can see that each commit has hash.

Comments

No Comments Yet.
Be the first to tell us what you think.
Git for beginners
Git for beginners

Are you learning Git ? Try our test we designed to help you progress faster.

Test yourself
25 Git questions that will help you to nail your job interview
25 Git questions that will help you to nail your job interview

Are you learning Git ? Try our test we designed to help you progress faster.

Test yourself