Jithin Pavithran
Jithin Pavithran

Reputation: 1351

Git Commit creates a new Head - PyCharm

When I commit my changes using PyCharm, it creates new Head.
How can I prevent this?
Why does this happen?
(I'm not familiar with using git via terminal)

Add:
The problem was my understanding of git. With the understanding of what is head and how git works, now this question seems silly to me.

PS: Understanding how git works under the hood is very important and useful.

Upvotes: 0

Views: 75

Answers (1)

Alex Aparin
Alex Aparin

Reputation: 4522

You should understand, that actually HEAD is pointer to your last commit in branch. It is common practice (change head pointer due adding new commits). Of course, you can change location of HEAD, but it can lead to leaks of changes (In the case of new commits). If you want to mark some commits then you should create new branch or tag.

Upvotes: 3

Related Questions