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

Re: svn commit: r14587 - trunk/contrib/client-side

From: Archie Cobbs <archie_at_dellroad.org>
Date: 2005-05-06 18:54:46 CEST

Philip Martin wrote:
>>--- trunk/contrib/client-side/svnmerge (original)
>>+++ trunk/contrib/client-side/svnmerge Thu May 5 20:15:07 2005
>>@@ -689,8 +689,7 @@
>> # Get latest revision of head
>> report checking latest revision of "${HEAD_URL}"
>> HEAD_REVISION=`"${SVN_MERGE_SVN}" proplist --revprop -r HEAD "${HEAD_URL}" \
>>- | grep '^Unversioned properties on revision' \
>>- | sed 's/^Unversioned properties on revision \([0-9]\{1,\}\).*$/\1/g'`
>>+ | head -1 | sed 's/.* \([0-9]\{1,\}\).*$/\1/g'`
>
> 'head -1' has some portability problems: some versions of GNU head
> only support the POSIX form 'head -n1' unless an environment variable
> is set to force compatibilty. On the other hand some older heads
> don't support 'head -n1'. The usual workaround is to use 'sed 1q'
> instead (warning untested):
>
> sed -e 's/.* \([0-9]\{1,\}\).*$/\1/g' -e 1q

Thanks for the info.

This script doesn't really pretend to be portable, and I'm sure there
are other portability problems. I'll fix this one though.

-Archie

__________________________________________________________________________
Archie Cobbs * CTO, Awarix * http://www.awarix.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri May 6 19:03:18 2005

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