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

Re: command line syntax for svn diff

From: Arwin Arni Nandagopal <arwin_at_collab.net>
Date: Sat, 28 Apr 2018 06:39:24 +0000

There are revision keywords like HEAD which references the latest revision and PREV which references the last changed revision of the target. E.g: SVN diff -rHEAD:PREV target.file will show the changes between the last changed revision for that file and the latest revision, which is effectively the change introduced by that last revision.

Arwin

________________________________
From: Bo Berglund <bo.berglund_at_gmail.com>
Sent: Saturday, April 28, 2018 10:53:35 AM
To: users_at_subversion.apache.org
Subject: command line syntax for svn diff

I want to examine the difference between two file revisions, one being
the file in the working copy and the other the same file as the
previous committed revision of that same file.
The diff should be sent to WinMerge for display.

In the WinMerge docs (http://manual.winmerge.org/Version_control.html)
they suggest to use this command line:
svn diff --diff-cmd "<path to WinMerge executable>" -x "-dl -dr" <file
to check>

But when I try this in a WC on a file that is part of the project
nothing at all happens:

svn diff --diff-cmd "C:\Programs\WinMerge\WinMergeU.exe" -x "-dl -dr"
espconfig.cpp

I suspect that the svn diff needs something more to work correctly,
the above command might only work with *local* uncommitted changes?

In SVNBook is shown the diff command as:
svn -diff -r 2:3 <filename>
where 2 and 3 are the revisions to compare.

But my problem is that the revisions where the file actually changed
last is not known, so how can I put the correct number into the
command?

There is also the --change parameter to svn diff, but the same problem
reappears: how to find out the revision where this particular file
changed in the past?

I am running Svn 1.9.7 command line client on Windows 7 X64.
I cannot install Tortoise because my Windows Explorer plug-in handler
is already filled to capacity...

--
Bo Berglund
Developer in Sweden
Received on 2018-04-28 08:39:45 CEST

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.