Answer the question
In order to leave comments, you need to log in
How to roll back changes to an uncommitted state?
Help out guys!
Kodil-kodil, but forgot to commit. Then I switched to the old commit. And how now to return my new code, which I did not have time to commit?
Don't kick too hard, I'm new to git.
Answer the question
In order to leave comments, you need to log in
If you used an IDE, then you probably stayed there. Git doesn't have them, but an IDE like php storm has its own version control (although it's probably more correct to say just a changelog) and your latest edits can be there.
If you switched to an old commit, then your changes were left on top, and if there were no conflicts, then just switch to the previous branch and commit. All after all happens on the same computer?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question