项目作者: suomela

项目描述 :
Better word-diff for git
高级语言: Shell
项目地址: git://github.com/suomela/gitwdiff.git
创建时间: 2013-01-29T14:41:34Z
项目社区:https://github.com/suomela/gitwdiff

开源协议:

下载


gitwdiff

Better word-diff for Git and SVN.

Usage

Add everything to your $PATH. Make sure you have wdiff installed.

Use gitwdiff ... instead of git diff ....

Use svnwdiff ... instead of svn diff ....

For the best results, copy the settings from gitconfig-example to
your ~/.gitconfig. After that:

  • Long lines are wrapped in the output
    (no horizontal scrolling in the pager).

  • The usual Git commands such as git diff, git show, and
    git status will use colours that are similar to the colour
    scheme of gitwdiff.

Git uses a pager by default. With SVN, you can try this:

  1. svnwdiff ... | less -R

Examples

More examples at: https://github.com/suomela/gitwdiff/tree/examples/example

gitwdiff

gitwdiff]

git diff —color-words

git diff --color-words

git diff —word-diff

git diff --word-diff

Dependencies

wdiff - http://www.gnu.org/software/wdiff/

Colours

Try gitwdiff1 or gitwdiff2 for alternative colour schemes.

See http://en.wikipedia.org/wiki/ANSI_escape_code for the colour codes.