Repository navigation
|
Say I have a lot of unstaged changes in a repo. I have a file or subdir selected in the |
Answered by
mark2185
Sep 5, 2022
Replies: 1 comment 4 replies
|
If you want to discard just a specific file, move the cursor to the file.
|
4 replies
Answer selected by
metov
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you want to discard just a specific file, move the cursor to the file.
ddiscard whatever is under the cursor, it's as if you wrotegit checkout -- <thing under cursor>. If it's a directory, it'll discard that directory. If it's a file, it'll discard that file.