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

Re: how to use environment variable

From: Ryan Schmidt <subversion-2006q2_at_ryandesign.com>
Date: 2006-05-06 14:29:33 CEST

On May 6, 2006, at 10:34, pipehappy wrote:

> When using svn command, it seems have to explicit path to the repos. I
> remember when using CVS, an environment variable can contain the
> default path and user can do not care about the path to repos.

When using svn commands that operate on a working copy, Subversion
obtains the repository URL from the working copy. You can see which
URL it's using by typing "svn info" while you're in the working copy
in question.

> Does Subversion have the similar facility that I can use some default
> URL to the repos?

For svn commands that do not operate on working copies, you must
specify the URL to the repository. Subversion has no facitily for
making this any easier, because it does not need to, because your
shell has the ability to define environment variables which you can
use for this purpose. For example, I have something like this in
my .bash_profile:

export REPO=https://svn.example.com

Then I can say things like:

svn checkout $REPO/project/trunk project-trunk

This is for the Bash shell; converting this for use with a different
shell, or Windows, is left as an exercise for the reader.

To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Sat May 6 14:30:31 2006

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.