Temporarily switch working copy to a specific Git commit

How to switch to specific Git commit without losing all the commits made after it?

I want that local files will be changed, but commits’ database will remain intact, only the current position pointer is set to currently selected commit.

I want to change files’ state to specific commit, run project and, when finished, restore files back to last commit.

How to do this without zipping the whole project’s folder?

4 Answers
4

Leave a Comment