Re: git checkout does not warn about tags without corresponding commits
- From
Miklos Vajna <vmiklos@frugalware.org>
- Date
- Jan 2, 2009, 15:04 UTC
- Message-ID
- <20090102150437.GN21154@genesis.frugalware.org>
- In-Reply-To
- <200901021325.58049.henrik@austad.us>
On Fri, Jan 02, 2009 at 01:25:57PM +0100, Henrik Austad <henrik@austad.us> wrote:
> I can see that there's no commit for this, but, when there's a tag. I thought > that a tag was just a commit-sha1 with a name attached, along with some tag > info and a signature. Can you really create a tag without a commit?
Sure, you can tag any object type (blob, tree, commit or tag), but usually only commits are tagged.
See for example the 'junio-gpg-pub' tag in git.git which tags a blob.