How to git reset –hard a subdirectory
With Git 2.23 (August 2019), you have the new command git restore (also presented here) git restore –source=HEAD –staged –worktree — aDirectory # or, shorter git restore -s@ -SW — aDirectory That would replace both the index and working tree with HEAD content, like an reset –hard would, but for a specific path. Original answer … Read more