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

Re: bug report "svn propset"

From: Paul Koning <Paul_Koning_at_dell.com>
Date: Wed, 18 Feb 2009 11:31:31 -0500

>>>>> "Mantas" == Mantas Balnys <mantas.balnys_at_nomagic.com> writes:

 Mantas> OS: Fedora 8 SVN: 1.4.4

 Mantas> Example: svn propset "propname" "-propvalue" file.txt svn:
 Mantas> invalid option character: p

 Mantas> It seems that propvalue can't start with '-'

Yes, it can.

Unix switches (options) begin with "-", and modern apps allow options
to appear anywhere in the command line. So "-propvalue" is the switch
"-p" with value "ropvalue".

There is also a standard Unix convention that says "there are no more
options in this command line". That is the way you deal with command
arguments that begin with "-". And Subversion supports this. You do
this by inserting "--" (two dashes) after the last option.

For example:

    svn propset -q -- propname -propvalue file.txt

Here -q is an option but -propvalue is a command argument. This will
do what you asked for.

   paul

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=1186881

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-02-18 17:32:41 CET

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.