Git Discard File Changes
(Updated: )
Discard uncommitted changes for a specific file.
bash
$git restore <filename>
$# Or
$git checkout -- <filename> Discard uncommitted changes for the current directory.
bash
$git restore .
$# Or
$git checkout -- .