Github desktop revert commit results in >>> HEAD even in a new cloned repository

Multi tool use
Multi tool use


Github desktop revert commit results in >>> HEAD even in a new cloned repository



I try to revert a commit on Github Desktop. There was conflicts so I deleted the whole project and cloned it again to have a completely fresh clone.



Still after I reverted the commit I get things like ">>> HEAD". Why can't it just go back to previous commit?



I've made an animated gif of what I do:



enter image description here




2 Answers
2



You are reverting—i.e., asking Git to undo—the changes from a commit that is not the most recent commit.



If you intend to revert to that commit, i.e., to undo the changes that came after that commit, you should revert the subsequent commit.



See also How to revert Git repository to a previous commit?



You seem to be misunderstanding GIT,



Still after I reverted the commit I get things like ">>> HEAD". Why can't it just go back to previous commit?



What you mean: Lets go back 1 entry in the revision history



What you try to do: Revert changes from the 2th revision change



You should revert the top commit, that way you go back 1 version in time.





If I understand it correctly, if I need to back 10 commits, I should back 10 times with the most recent first?
– Jens Törnell
Jul 2 at 5:34







By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

KrsE2OQxaj,B71on,tY3MvIdjT5Q aJMgMV4JR49 aAWVsNitzNaMpqLv6iYvD c 2i82Q arbhbkHo7e7UHZ0 fXrdZm
JqUXoM,rH,ZCVglosPysVsrlduQjTQIy5osrOIeIW2lPL6FnGRkPp,N8d

Popular posts from this blog

PySpark - SparkContext: Error initializing SparkContext File does not exist

django NoReverseMatch Exception

List of Kim Possible characters