Re: Individual file snapshots
- From
- Ron Garret <ron1@flownet.com>
- Date
- Feb 12, 2010, 17:24 UTC
- Message-ID
- <ron1-278C58.09242712022010@news.gmane.org>
- In-Reply-To
- <alpine.DEB.2.00.1002121316260.10583@ds9.cixit.se>
In article <alpine.DEB.2.00.1002121316260.10583@ds9.cixit.se>, Peter Krefting <peter@softwolves.pp.se> wrote:
Show 16 quoted lines
> Ron Garret: > > > I would like to be able to store snapshots of individual files without > > making a commit on the main branch. > > git hash-object -w filename > > will add the file to the object database, outputting it's hash value. > > git tag mytag hashvalue > > creates a tag "mytag" pointing to that file. > > git show mytag > > will output the file you put in.
Ah, cool! Thanks. I knew about git hash-object, but I did not know that you could tag the resulting hash. I thought you could only tag commit objects.
rg