Updated contrib/vim/patchreview.* to version 0.2.1

1) adds a :DiffReview command to review code changes
   in the current workspace.

2) removes the need to have patchutils (specifically filterdiff)
   installed on the system by implementing patch extraction in
   pure vim script.
This commit is contained in:
Manpreet Singh 2010-02-24 13:12:17 -08:00
parent 155fe1239e
commit 712fecc765
2 changed files with 881 additions and 264 deletions

View File

@ -1,30 +1,38 @@
*patchreview.txt* Vim global plugin for doing single or multipatch code reviews
*patchreview.txt* Vim global plugin for doing single, multi-patch or diff code reviews
Version v0.2.1 (for Vim version 7.0 or higher)
Author: Manpreet Singh (junkblocker-CAT-yahoo-DOG-com)
(Replace -CAT- and -DOG- with @ and . first)
Copyright (C) 2006 by Manpreet Singh
Author: Manpreet Singh < junkblocker@yahoo.com >
Copyright (C) 2006-2010 by Manpreet Singh
License : This file is placed in the public domain.
=============================================================================
CONTENTS *patchreview* *patchreview-contents*
CONTENTS *patchreview* *diffreview* *patchreview-contents*
1. Contents.........................................: |patchreview-contents|
2. Introduction.....................................: |patchreview-intro|
3. PatchReview options..............................: |patchreview-options|
4. PatchReview Usage................................: |patchreview-usage|
4.1 PatchReview Usage............................: |:PatchReview|
4.2 PatchReview Usage............................: |:PatchReviewCleanup|
4.1 DiffReview Usage.............................: |:DiffReview|
4.2 PatchReview Usage............................: |:PatchReview|
4.3 DiffReviewCleanup Usage......................: |:DiffReviewCleanup|
4.4 PatchReviewCleanup Usage.....................: |:PatchReviewCleanup|
=============================================================================
PatchReview Introduction *patchreview-intro*
The Patch Review plugin allows single or multipatch code review to be done in
VIM. VIM provides the |:diffpatch| command to do single file reviews but can
not handle patch files containing multiple patches as is common with software
development projects. This plugin provides that missing functionality. It also
tries to improve on |:diffpatch|'s behaviour of creating the patched files in
The Patch Review plugin allows easy single or multipatch code or diff reviews.
It opens each affected file in the patch or in a workspace diff in a diff view
in a separate tab.
VIM provides the |:diffpatch| and related commands to do single file reviews
but can not handle patch files containing multiple patches as is common with
software development projects. This plugin provides that missing
functionality.
It also improves on |:diffpatch|'s behaviour of creating the patched files in
the same directory as original file which can lead to project workspace
pollution.
@ -32,66 +40,81 @@ pollution.
PatchReview Options *patchreview-options*
g:patchreview_filterdiff : Optional path to filterdiff binary. PatchReview
tries to locate filterdiff on system path
automatically. If the binary is not on system
path, this option tell PatchReview the full path
to the binary. This option, if specified,
overrides the default filterdiff binary on the
path.
examples:
(On Windows with Cygwin)
let g:patchreview_filterdiff = 'c:\\cygwin\\bin\\filterdiff.exe'
(On *nix systems)
let g:patchreview_filterdiff = '/usr/bin/filterdiff'
g:patchreview_patch : Optional path to patch binary. PatchReview tries
to locate patch on system path automatically. If
the binary is not on system path, this option
tell PatchReview the full path to the binary.
This option, if specified, overrides the default
patch binary on the path.
examples:
(On Windows with Cygwin)
let g:patchreview_patch = 'c:\\cygwin\\bin\\patch.exe'
(On *nix systems)
let g:patchreview_patch = '/usr/bin/gpatch'
g:patchreview_tmpdir : Optional path where the plugin can save temporary
files. If this is not specified, the plugin tries to
use TMP, TEMP and TMPDIR environment variables in
succession.
g:patchreview_tmpdir = {string}
Optional path where the plugin can save temporary files. If this is not
specified, the plugin tries to use TMP, TEMP and TMPDIR environment
variables in succession.
examples:
(On Windows) let g:patchreview_tmpdir = 'c:\\tmp'
(On *nix systems) let g:patchreview_tmpdir = '~/tmp'
(On Windows) >
let g:patchreview_tmpdir = 'c:\\tmp'
<
(On *nix systems) >
let g:patchreview_tmpdir = '~/tmp'
<
g:patchreview_filterdiff = {string}
Optional path to filterdiff binary. PatchReview tries to locate
filterdiff on system path automatically. If the binary is not on system
path, this option tell PatchReview the full path to the binary. This
option, if specified, overrides the default filterdiff binary on the
path.
examples:
(On Windows with Cygwin)
>
let g:patchreview_filterdiff = 'c:\\cygwin\\bin\\filterdiff.exe'
<
(On *nix systems)
>
let g:patchreview_filterdiff = '/usr/bin/filterdiff'
<
g:patchreview_patch = {string}
Optional path to patch binary. PatchReview tries to locate patch on
system path automatically. If the binary is not on system path, this
option tell PatchReview the full path to the binary. This option, if
specified, overrides the default patch binary on the path.
examples:
(On Windows with Cygwin) >
let g:patchreview_patch = 'c:\\cygwin\\bin\\patch.exe'
<
(On *nix systems) >
let g:patchreview_patch = '/usr/bin/gpatch'
<
=============================================================================
PatchReview Usage *patchreview-usage*
*:DiffReview*
:DiffReview
Perform a diff review in the current directory under version control.
Currently supports Mercurial (hg), Subversion (svn), CVS, Bazaar (bzr) and
Monotone.
*:PatchReview*
:PatchReview patchfile_path [optional_source_directory]
Perform a patch review in the current directory based on the supplied
patchfile_path. If optional_source_directory is specified, patchreview is
done on that directory. Othewise, the current directory is assumed to be
done on that directory. Otherwise, the current directory is assumed to be
the source directory.
Only supports context or unified format patches.
*:DiffReviewCleanup*
*:PatchReviewCleanup*
:DiffReviewCleanup
:PatchReviewCleanup
After you are done using the :PatchReview command, you can cleanup the
temporary files in the temporary directory using this command.
After you are done using the :DiffReview or :PatchReview command, you can
cleanup the temporary files in the temporary directory using either of
these commands.
=============================================================================
vim: ft=help:ts=2:sts=2:sw=2:tw=78:tw=78
------------------------------------------------------------------------------
vim: ft=help:ts=2:sts=2:sw=2:tw=78:norl:

File diff suppressed because it is too large Load Diff