I want to use a variable in a svn setprop svn:externals
command in a shell script.
The path is set as a variable, and works fine:
LOCALPATH="/some/path"
TARGETFOLDER="folder"
svn propset svn:externals 'dir -r100 http://svn.example.com/repos/trunk' $LOCALPATH/$TARGETFOLDER/externals
However, if I try to use a variable for the revision number, it doesn't work:
LOCALPATH="/some/path"
TARGETFOLDER="folder"
REV="100"
PROP="'dir -r$REV http://svn.example.com/repos/trunk'"
echo $PROP
svn propset svn:externals $PROP $LOCALPATH/$TARGETFOLDER/externals
The PROP
variable is echoed correctly, but the propset
doesn't work. I always get the following error:
svn: Cannot specify revision for setting versioned property 'svn:externals'
Any help would be appreciated.