0

I'm trying to learn git by trying different commands.

I'm using "GitKraken" to visualize how the git commit "graph" changes as and when I try different commands.

At one point , I used "git reset --hard HEAD~2" to go back to the previous 2 commits.

Till that time the graph was linear. When I made changes to my file, staged them and committed them, the new commit became non-linear somehow.

I wish to make that particular commit linear along with the other commits. Please refer to the image link mentioned

Git Non-Linear state

  • Try `git rebase $commit`. `$commit` is `Process 2 added by UtileHomme1`. – ElpieKay Sep 22 '17 at 13:06
  • I tried it on `Hello Jatin (the commit after Process 2)`. I did this on my own before I saw your comment. I have this now!! [link](http://imagizer.imageshack.us/a/img924/2558/azTTuA.jpg) – Jatin Sharma Sep 22 '17 at 13:42

0 Answers0