[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Request: way to get -rBASE with keywords expanded without using the network

From: Stephen Davis <stephendavis_at_mac.com>
Date: 2005-10-13 00:46:12 CEST

On Oct 12, 2005, at 12:57 PM, Vincent Starre wrote:

> "svn cat -rBASE" uses the network. Sometimes, I might want that.
> Not today! :)

This was true pre-1.2.2 (?) but I think it was fixed in 1.2.3. Which
version are you running?

stephen

> So in order to mimick that, without using the network, I had to do
> this:
>
> ~/bin/svnReview:
> svn diff "$1" --diff-cmd ~/bin/svnReviewDiff -x "$1" | sed '1,2{d;}'
>
> ~/bin/svnReviewDiff:
> diff "$7" "$1" | patch -o/dev/stdout "$6" | sed '1d'
>
> $ svnReview file.c
>
>
> what that's doing:
> svn cat uses the network, svn diff does not. So I use svn diff to
> get the actual file, passing my one-liner as a --diff-cmd
> BUT, svn diff doesnt generate diffs by expanding the keywords in
> base, it does so by /removing/ keywords from the modified copy
> (highly sloppy way to behave, imo)
> So we apply the difference between the modified file and the
> modified file with keywords removed, to the base file. Presto: the
> simplest imaginable operation made needlessly complex, and I didnt
> need to wait 3 seconds for the network to do its thing in order to
> get it.
>
> come on, there needs to be a better way than that :)
Received on Thu Oct 13 00:47:51 2005

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.