Question

We are currently using trac and have become dependent on one of its features. Within the source browser, you can press View Changes and see all the diffs between 2 revisions. And we love being able to download a zip file that contains all the files modified, in their directory structure.

Is there another open-source application that can do that?

Was it helpful?

Solution

It's very easy to get the same result using just commandline svn. You could write a script that will get those values for you if your new trac-replacement won't have that feature. Here's the demo script in bash:

#!/bin/bash
// replace 100 and 120 with revision numbers
svn diff -r 100:120 "svn://path.to.your.svn.repo" > svn.rev.diff
gzip svn.rev.diff

This will give you a nice gzipped diff file (svn.rev.diff.gz) between two revisions. Of course you could add some params to it instead of hardcoding the numbers but that's just to show how this can be done.

OTHER TIPS

get_file.sh with this content would work

echo "++++++++++++++++++++++++++++++++++++++++++"
echo "usage ./get_file.sh 13910 13914"
echo "++++++++++++++++++++++++++++++++++++++++++"

REPO=http://svn.urcompany.com/urproduct/trunk
for i in $(svn diff --summarize -r $1:$2 $REPO | awk '{ print $2 }'); do p=$(echo $i | sed -e "s{$REPO/{{"); mkdir -p $(dirname $p); echo $i; svn export --force $i $p; done

Thanks to http://www.clearintent.co.uk/subversion/technical/support/output_a_list_of_changes_between_2_revisions/699

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top