Web-based diffs for code reviews: webrev

webrev refers to both the tool for generating web-based diffs for use in code reviews and its output. The script, webrev.ksh, is maintained in the Code Tools Project.

webrev.ksh crawls over your changes to generate a set of web-based views of the differences in your code. The different views allow reviewers to easily look at your proposed changes, selecting the appropriate difference format based on the type of file, the type of change, and their own preferences.

Examples

ksh ./webrev.ksh -N -r <REV>

Generate diffs between revision <REV> and the tip. Output created under the ./webrev/ directory.

ksh ./webrev.ksh -m -N -c <BUGID>

Force the use of Mercurial to generate diffs between all modified files and the current tip. At the top of the main page Include a clickable link to <BUGID> in the OpenJDK Bug System. Output to ./webrev/.

ksh WDIR=<OUTDIR> ./webrev.ksh <FILE>

Useful when generating diffs across multiple repositories in the forest, the <FILE> contains a list of files to diff. Output to alternate location <OUTDIR>.

ksh ./webrev.ksh -help

Complete list of options.

Further information