Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- For this, we will be using the python-bugzilla module
- pip install python-bugzilla
- This provides 'bugzilla' command, which is the interface we'll be using.
- bugzilla has a "modify" sub command which allows us to update a bug via the CLI.
- The most important piece of this is to pass the following argument, which surpresses email updates.
- --field=minor_update=1
- To update a single bug, you can either login via the 'login' subcommand or pass your username and password at run time.
- bugzilla login
- bugzilla modify --flag qa_ack+ --field=minor_update=1 12345678 (12345678) is the bug id
- or
- bugzilla modify --username myname@redhat.com --password 12345 --flag qa_ack+ --field=minor_update=1 12345678
- If you are doing multiple updates you can either add them all as space delimited entries on the end of the bugzilla command, or you can create a text file with all the ids.
- The second option allows you to iterate over each id, to lessen the chances of a bugzilla timeout.
- An example of how to update the qe_test_coverage flag to - for all bugs in the list.
- for id in $(cat bugids.txt); do echo $id && bugzilla modify --flag qe_test_coverage- --field=minor_update=1 $id; done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement