git checkout filename
时间: 2023-10-26 11:37:59 浏览: 123
git使用1
`git checkout filename` is used to discard changes made to a specific file and restore it to its last committed state in the current branch. This command is useful when you have made changes to a file and want to revert those changes. Keep in mind that using this command will permanently discard any changes made to the file since the last commit.
阅读全文