3 # This script is used to generate the list of fixed bugs that
4 # appears in the release notes files, with HTML formatting.
6 # Note: This script could take a while until all details have
7 # been fetched from bugzilla.
11 # $ bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3
12 # $ bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 > bugfixes
13 # $ bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 | tee bugfixes
14 # $ DRYRUN=yes bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3
15 # $ DRYRUN=yes bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 | wc -l
18 # regex pattern: trim before url
19 trim_before
='s/.*\(http\)/\1/'
21 # regex pattern: trim after url
22 trim_after
='s/\(show_bug.cgi?id=[0-9]*\).*/\1/'
24 # regex pattern: always use https
25 use_https
='s/http:/https:/'
27 # extract fdo urls from commit log
28 urls
=$
(git log $
* |
grep 'bugs.freedesktop.org/show_bug' |
sed -e $trim_before -e $trim_after -e $use_https |
sort |
uniq)
30 # if DRYRUN is set to "yes", simply print the URLs and don't fetch the
31 # details from fdo bugzilla.
34 if [ "x$DRYRUN" = xyes
]; then
45 id
=$
(echo $i | cut
-d'=' -f2)
46 summary
=$
(wget
--quiet -O - $i |
grep -e '<title>.*</title>' |
sed -e 's/ *<title>Bug [0-9]\+ – \(.*\)<\/title>/\1/')
47 echo "<li><a href=\"$i\">Bug $id</a> - $summary</li>"