how to remove all the local changes in git code example
Example 1: revert unstaged changes git
git checkout -- path/to/file/to/revert
Example 2: how to undo git clean -fd command
git clean -fdxn
git checkout -- path/to/file/to/revert
git clean -fdxn