The GNU coding standard requires every conforming source distribution to ship a NEWS
file containing a summary of changes. I think this is a good idea (but that does not matter here) and since I am using git I thought it would be great to autogenerate that file. My idea was to use the message of annotated tags (when I create a tag I also write a summary of changes) and put them into this file. However, I did not find a way to access the message in an easy way. I used the following code:
git tag -l -n100 <tag-name>
Which gives me
<tag-name> Message-Header 1
- foo
- bar
- bla
- blup
I would like to get the message without <tag-name>
and those spaces. For commit messages I can use
git --format='%s %b' <id> # %s = subject, %b = body of commit message
Is there a similar command for the messages of annotated commit tags or is it not meant for such purposes?