Version 1 (modified by 14 years ago) (diff) | ,
---|
History of an individual file
Text mode
git log -p <filename>
Graphically
gitk <filename>
Find revision by date
This is kind of obtuse, and I really recommend git log
or gitk
. If you insist:
git rev-list -n 1 --before="2009-07-27 13:37" master
This finds one revision (-n 1) before a certain date. You can use this with git checkout
(see below).
Check out old version of a file
Find the old revision by using git log
(see above).
git checkout <revision> <file>
Reverting to the current version (HEAD):
git checkout HEAD <file>
Attachments (1)
-
git-touch.py (1.3 KB) - added by 14 years ago.
script to set local file mod times to git commit times
Download all attachments as: .zip