3 REPO_NAME
=$
(basename $
(git config
--get remote.origin.url
) | cut
-d'.' -f1)
4 git pull
--tags origin master
&> /dev
/null
6 echo "<h1>$REPO_NAME Changelog</h1>"
8 TAG_START
=$
(git tag |
sort -Vr |
head -1)
10 # check to see if there is a tag start first.
11 if [ ! -z "${TAG_START}" ]; then
12 head_tag_diff
=$
(git rev-list HEAD ^
${TAG_START} |
wc -l)
13 if [ $head_tag_diff -eq 0 ]; then
14 # HEAD and latest tag intersect. Instead try and find a previous tag and use that as the start diff
16 TAG_START
=$
(git tag |
sort -Vr |
head -2 |
sort -V |
head -1)
21 echo "<h2>tag: ${TAG_START} -> ${TAG_END}</h2>"
22 git log
--pretty=format
:"<li> <a href=https://osm.etsi.org/gitweb/?p=osm/$REPO_NAME.git;a=commitdiff;h=%H>%h •</a> %s</li> " --reverse ${TAG_START}..
${TAG_END}
24 # no tag, just give the full log
25 git log
--pretty=format
:"<li> <a href=https://osm.etsi.org/gitweb/?p=osm/$REPO_NAME.git;a=commitdiff;h=%H>%h •</a> %s</li> " --reverse