Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
0 points
bqmjjx0kac
4y ago
0 comments
Save
Share
Is `git reset --hard` not undoable with `git reflog` and another `git reset --hard`?
0 comments
2 comments · 1 top-level
top
newest
oldest
jlokier
4y ago
· 1 in thread
No, it wipes all local changes to tracked files in your worktree that haven't been committed yet.
nerdponx
4y ago
I really wish it would warn you with a y/n prompt before doing this. Same with `git checkout` when overwriting unsaved files. You should need a `--force` option to bypass the prompt. Or it could simply refuse to make the change without `--force`.
j
/
k
navigate · click thread line to collapse