Jump to >

This documentation covers the in-development release of RBTools. You can see the latest stable docs or all previous versions.

review

rbt review provides several features for creating and editing reviews.

Usage

$ rbt review <subcommand> [options] 

This command provides several subcommands:

For help on individual subcommands, run:

$ rbt review <subcommand> --help

Creating and editing reviews

To create a new draft, or update an existing one, use rbt review edit. This command allows specifying the review header and footer text, as well as setting the “Ship It!” state. For example:

$ rbt review edit -r 23 --header "Looks good" --markdown --ship-it

A draft review will also be created if necessary when creating comments.

Adding comments

There are three commands used to add comments to a draft review, corresponding to the three types of comments that Review Board has.

For a general comment, not attached to any kind of content:

$ rbt review add-general-comment -r 23 -t "Comment text" --open-issue

For a comment on a file attachment:

$ rbt review add-file-attachment-comment -r 23 --file-attachment-id 96 -t "Comment text"

Finally, for a comment on a diff:

$ rbt review add-diff-comment -r 23 --diff-revision 2 -f test.py --line 485 --num-lines 4 -t "Comment text"

See the help options for each of these commands for full usage details.

Publishing reviews

When a draft review is ready, publishing it is simple:

$ rbt review publish -r 23

Discarding reviews

On the other hand, to discard a draft review, run:

$ rbt review discard -r 23

Options

-d, --debug

Displays debug output.

This information can be valuable when debugging problems running the command.

The default can be set in DEBUG in .reviewboardrc.

--json

Output results as JSON data instead of text.

The default can be set in JSON_OUTPUT in .reviewboardrc.

New in version 3.0.