meaning of the command "git checkout ."
11,228
git checkout with
<paths>
[...] is used to restore modified or deleted paths to their original contents from the index or replace paths with the contents from a named (most often a commit-ish).
See documentation, especially here and here: .
is treated as <pathspec>
in your case, adressing the current directory. The current HEAD
revision of all files in the given <pathspec>
, so in your case everything in your base directory, are checked out.
Related videos on Youtube
Author by
Srivatsa M Hegde
Updated on June 04, 2022Comments
-
Srivatsa M Hegde almost 2 years
While I understand that the command in the title is akin to undo the changes to the current repository, I am unable to understand how it actually works or how to read the command. Any leads would be a great help.