git tag: don't complain of empty messages

4 messages, 2 authors, 2016-08-11 · open the first message on its own page

git tag: don't complain of empty messages

From: Han-Wen Nienhuys <hidden>
Date: 2016-08-11 20:32:54

Hello,

GIT refuses to set annotated tags without a comment. I think this is a 
silly restriction when the message is explicitly set to the empty string.

The attached patch should fix this;  Unfortunately, I've been unable to 
test it. Running the script with sh -x stops at

++exec /home/hanwen/usr/pkg/git/bin/git-sh-setup

-- 
  Han-Wen Nienhuys - hanwen@xs4all.nl - http://www.xs4all.nl/~hanwen

Re: git tag: don't complain of empty messages

From: Han-Wen Nienhuys <hidden>
Date: 2016-08-11 19:26:41

Johannes Schindelin escreveu:
Hi,

On Wed, 15 Nov 2006, Han-Wen Nienhuys wrote:
quoted
GIT refuses to set annotated tags without a comment. I think this is a silly
restriction when the message is explicitly set to the empty string.
I think that this behaviour is on purpose: The tag will be identified 
(like all objects in git) by its contents. The rationale: the filename 
does not matter, since the tag _object_ is not identified by it. So, in 
case you lose your .git/refs/tags/ directory, you can still reconstruct 
the tags with "git-fsck-objects --full".
Without a message, the tag can still be identified by its name, which is 
in the tag object contents.

-- 

Re: git tag: don't complain of empty messages

From: Johannes Schindelin <hidden>
Date: 2016-08-11 19:42:02

Hi,

On Wed, 15 Nov 2006, Han-Wen Nienhuys wrote:
GIT refuses to set annotated tags without a comment. I think this is a silly
restriction when the message is explicitly set to the empty string.
I think that this behaviour is on purpose: The tag will be identified 
(like all objects in git) by its contents. The rationale: the filename 
does not matter, since the tag _object_ is not identified by it. So, in 
case you lose your .git/refs/tags/ directory, you can still reconstruct 
the tags with "git-fsck-objects --full".

Ciao,
Dscho

Re: git tag: don't complain of empty messages

From: Johannes Schindelin <hidden>
Date: 2016-08-11 20:31:34

Hi,

On Wed, 15 Nov 2006, Han-Wen Nienhuys wrote:
Without a message, the tag can still be identified by its name, which is 
in the tag object contents.
You are correct. Acked-by: me.

Ciao,
Dscho
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help