We'd like to annotate our commits with git notes add
, which works fine. To get a list of all commits with notes we use this command
git notes | cut -d' ' -f2 | xargs -ihash git log hash -1
Now we are looking for the notes of a branch only. I'm at a loss here since the notes don't know anything about branches. May be there's a way to start with git log
and ask git notes
wheter there's a note for the commit. But I'm nut sure wheter this is to slow for big repositories.
Any ideas?
I would start with this:
See
git help log
for additional things you can put in the format string to fix up the output the way you want it...