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

Re: How to determine the source of a copy

From: Stanimir Stamenkov <s7an10_at_netscape.net>
Date: Sat, 03 Apr 2010 15:29:12 +0300

Tue, 30 Mar 2010 13:18:14 -0430, /Brian Mearns/:

> Various client tools seem to know what path and revision a copy was
> created from (e.g., Tortoise's revision graph). Can the svn command
> line tool get me this information? Is there anyway I can get this from
> a hook script?

Not sure if this would be sufficient for you
<http://svnbook.red-bean.com/en/1.5/svn.ref.svn.c.log.html>:

> With --verbose, svn log will also print all affected paths with each
> log message. With --quiet, svn log will not print the log message
> body itself (this is compatible with --verbose).
> (...)
> The --verbose option causes svn log to include information about the
> paths that were changed in each displayed revision. These paths
> appear, one path per line of output, with action codes that indicate
> what type of change was made to the path.
> (...)
> In addition to the action codes which precede the changed paths, svn
> log with the --verbose option will note whether a path was added or
> replaced as the result of a copy operation. It does so by printing
> (from COPY-FROM-PATH:COPY-FROM-REV) after such paths.

Using the --xml option one could process the result through an XSLT, for
example, and not parse the text log manually, also.

-- 
Stanimir
Received on 2010-04-03 14:30:10 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.