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

RE: Re: Getting HEAD revision number from a URL

From: Peter Yamamoto <peter.yamamoto_at_page44.com>
Date: 2004-10-29 20:07:41 CEST

Change the ' to ", and the internal " to \"...

Works for me under WinXP cmd shell.

C:\ProjectsSVN>svn log -q -v -rHEAD | perl -ne "/^r(\d+)/&&print \"set
HeadRev=$
1\""
set HeadRev=34

C:\ProjectsSVN>

Peter

-----Original Message-----
From: Juanma Barranquero [mailto:lektu@mi.madritel.es]
Sent: Thursday, October 28, 2004 4:51 PM
To: Subversion Users
Subject: Re: Getting HEAD revision number from a URL

On Wed, 27 Oct 2004 19:23:26 -0700, J Robert Ray <jrray@imageworks.com>
wrote:

> None of these work for me because my shell swallows "$1", but this
> works and it even shorter:
>
> svn log -q -v -rHEAD <URI> | perl -ne '/^r(\d+)/&&print"set
HeadRev=$1"'

Here's the opposite. Neither one of the two shells available to me (on
WinXP) groks single-quote args, so I cannot use -e '...' with Perl
one-liners.

                                                           /L/e/k/t/u

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Fri Oct 29 20:08:18 2004

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.