3 # Copyright (C) 2009-2010 Red Hat Inc.
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 # In 'make dist' this is used to update the top level 'BUGS' file with
20 # the current bug list from Red Hat Bugzilla (bugzilla.redhat.com).
22 # First of all fetch the bugs from the database. This might fail,
23 # eg. if there is no net access or no 'bugzilla' program, but if that
24 # happens just exit and leave the BUGS file alone.
26 bugzilla query -c libguestfs --outputformat='%{bug_id} %{bug_status} %{short_desc}' > .bugs.tmp || exit 0
28 # Any errors from now on are fatal.
32 echo 'NOTE: This file is automatically generated from "update-bugs.sh".'
33 echo -n 'Last updated: ' ; date +'%Y-%m-%d'
35 This contains a local list of the bugs that are open against
36 libguestfs. Bugs are tracked in the Red Hat Bugzilla database
37 at https://bugzilla.redhat.com/ and to report a new bug you
38 should follow this link:
40 https://bugzilla.redhat.com/enter_bug.cgi?component=libguestfs&product=Virtualization+Tools
42 When reporting a new bug, please check:
44 - That the bug has not been reported already.
45 - That you are testing a recent version.
46 - Describe the bug accurately, and give a way to reproduce it.
47 - Include the version of libguestfs, distro version and any other
49 - Attach the complete output of "libguestfs-test-tool".
53 while read bugno status summary; do
54 # Ignore CLOSED bugs in this list.
55 if [ "$status" = "CLOSED" ]; then continue; fi
57 # Treat ASSIGNED the same as NEW.
58 # Treat MODIFIED, POST and ON_QA as the same.
60 ASSIGNED) bugclass=NEW ;;
61 POST|ON_QA) bugclass=MODIFIED ;;
62 *) bugclass=$status ;;
65 # 'bugzilla' command returns the bugs sorted by status, NEW, ASSIGNED,
66 # MODIFIED, ..., CLOSED. Therefore start a new section when the
67 # status field changes.
68 if [ "$bugclass" != "$lastclass" ]; then
69 echo '--------------------------------------------------'
72 echo 'Bugs in NEW or ASSIGNED state are open and waiting for someone to fix.' ;;
74 echo 'Bugs in NEEDINFO state require additional information.' ;;
76 echo 'Bugs in MODIFIED, POST or ON_QA state are fixed.'
77 echo 'You can help by testing the fixes.'
80 echo "These bugs are in the $status state." ;;
87 echo "$bugno $status https://bugzilla.redhat.com/show_bug.cgi?id=$bugno"
92 echo "End of BUGS file."
94 # Clean up temporary file.