Subversion: Difference between revisions
Jump to navigation
Jump to search
(Created page with '<source lang="bash"> svn co svn+ssh://ftp.noekeon.org/opt/www/daemenj/web/private/SVN/Keccak </source>') |
(Colored diff) |
||
Line 1: | Line 1: | ||
== Configuration == |
|||
<ul> |
|||
<li> '''Colored diff''' — Either define ''colordiff'' as <tt>diff-cmd</tt> in <tt>~/.subversion/config</tt>:</li> |
|||
<source lang="text"> |
|||
diff-cmd = colordiff |
|||
</source> |
|||
However, to keep the internal svn diff tool, you need to define your own function & alias. This will also highlight diff header in green: |
|||
<source lang="bash"> |
|||
function svnwrap() |
|||
{ |
|||
if [ "$1" = "diff" ] ; then |
|||
"svn" "$@" | colordiff | less -FRX |
|||
else |
|||
"svn" "$@" |
|||
fi |
|||
} |
|||
alias svn=svnwrap |
|||
</source> |
|||
To page the output, use <code>| less -R</code> |
|||
</ul> |
|||
== Examples == |
|||
* Checking out a project |
|||
<source lang="bash"> |
<source lang="bash"> |
||
svn co svn+ssh://ftp.noekeon.org/opt/www/daemenj/web/private/SVN/Keccak |
svn co svn+ssh://ftp.noekeon.org/opt/www/daemenj/web/private/SVN/Keccak |
Revision as of 15:10, 28 February 2011
Configuration
- Colored diff — Either define colordiff as diff-cmd in ~/.subversion/config:
diff-cmd = colordiff
However, to keep the internal svn diff tool, you need to define your own function & alias. This will also highlight diff header in green:
function svnwrap()
{
if [ "$1" = "diff" ] ; then
"svn" "$@" | colordiff | less -FRX
else
"svn" "$@"
fi
}
alias svn=svnwrap
To page the output, use | less -R
Examples
- Checking out a project
svn co svn+ssh://ftp.noekeon.org/opt/www/daemenj/web/private/SVN/Keccak