For your .bashrc file:
alias gitdifflogmesg="perl -ne 'BEGIN {print \"[[[\";} /^\\+\\+\\+
b\\/(\\S+)/ && print \"\\n\\n* \$1\"; /^@\
@.*[ *]([^ ]+)\(/ && print \"\\n (\$1).\"; END { print \"\\n\\n]]]\\n\";}'"
Usage: cat malloc.patch | gitdifflogmesg
This lists the files you've changed as * dir/file with all the functions
modified as (function name) underneath.
A good patch to test this on is here:
https://issues.apache.org/jira/secure/attachment/12701904/malloc.patch (if
only for mass of ammunition :)
Expected output:
* DocFormats/api/src/Operations.c
(DFConcreteDocumentRelease).
* DocFormats/core/src/common/DFTable.c
(DFTableDimensionsMake).
(DFCellRelease).
* DocFormats/core/src/css/CSS.c
(ContentPartTypeString).
<snip long list>
]]]
Where no (function) is mentioned, something else happened, like a new
#include entry.
Of course log message sometimes don't need to be in that much depth, but,
such a list can sometimes be rather handy, and it saves much typing, all
that is then needed is to add the descs for the changes, if so desired.
It probably needs more improvement, but, this is a good starting point I
think.
G
--
Visit my Coding Diary: http://gabriela-gibson.blogspot.com/