Say I have a directory containing hundreds of files. I modify several of them, but afterwards I realize my changes are bad. If I do:
git checkout whole_folder
Then everything gets checked out again, and I have to recompile everything. Is there a way to make checkout affect only modified files, or do I need to run checkout
on each file separately?
git checkout -- <path>
(the slightly safer version ofgit checkout whole_folder
) the timestamps remain the same for files that aren't changed by that command. That means that your build process should still only be rebuilding the the files that it minimally thinks it needs to based on mtimes. – Mark Longairgit checkout -- whole_folder
? – Geo