Git revert of uncommited Changes

To revert uncommited changes in your git repository and reset a project back to the latest commited version, just type in

git reset --hard  

This will revert all modified but uncommited changes in your respository.

If you also want to get rid of all untracked files and directories you need also to run

git clean -fd  

Now your respository should be clean again.

Andreas Fritzler

Data Jedi | Cloud and Big Data Expert | Machine Learning Enthusiast | Deep Learning Fanatic @SAP Opinions are my own