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

Tortoise SVN: how can I tell that a file is new from the command line?

From: Mac <playlife69_at_gmail.com>
Date: Thu, 22 Jan 2009 08:45:54 -0800 (PST)

I am using Tortoise SVN from Windows command line. Say I want to run
something like this:

C:\>"Program Files\TortoiseSVN\bin\TortoiseProc.exe" /command:cat /
path:"c:\svn rumba\rumba-0431\test4.txt" /revision:PREV /savepath:"c:
\Documents and Settings\mc21262\Desktop\foo.txt"

The above works great, but only if test4.txt has a previous revision.
If it doesn't, SVN pops an error message box on the screen because it
cannot find a previous revision.

I heard one way around this issue is to use the 'log' command. Sort of
like this:

C:\>"Program Files\TortoiseSVN\bin\TortoiseProc.exe" /command:log /
path:"c:\svn rumba\rum

The reasoning is that if the log contains only 1 line, then this means
that the file is new and therefore has no previous revision. The
problem with doing it this way is that in Tortoise SVN opens up an
actual window with the log contents.

Essentially what I'm looking for is some kind of command line output
that will tell me whether or not a given file can be diffed against a
previous revision. If it's a new file, obviously it cannot be diffed.

So basically I want to be able to tell that a given file is new. How
do I do that?

What are my options?



To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2009-01-22 17:55:30 CET

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