Make SVN Commit also print the diff -


when svn commit , let svn editor pick i'd love svn editor show diff of files have changed instead of list of files. helps jog memory when writing detailed commit messages. ideas on how accomplish?

looks script here works after all.

from - http://push.cx/2007/seeing-subversion-diffs-for-commit-messages

needed make few changes. i'll paste entire script here

create file, name svn in case it's put in ~/bin

#!/bin/sh realsvn=/usr/bin/svn  args="$@"  if [ "$1" = "commit" -o "$1" = "ci" ];     shift # pop off $1 diff     template=`mktemp -t tmp`     $realsvn diff "$@" > "$template"     $realsvn $args --editor-cmd="~/bin/svn-diff-editor '$template'" else     $realsvn $args fi 

and create file named ~/bin/svn-diff-editor

echo >> "$2" cat "$1" >> "$2" rm "$1" $svn_editor "$2" 

for osx had add '-t tmp' mktmp , orig script had $visual did not have , had $svn_editor set instead, once changed last line of svn-diff-editor worked.


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -