Re: The use of SVNROOT
From: Ryan Schmidt <subversion-2010a_at_ryandesign.com>
Date: Fri, 5 Mar 2010 17:01:03 -0600
On Mar 5, 2010, at 14:11, Eramo, Mark wrote:
> I am working with Subversion 1.6.9 and was wondering if there was a way to setup the SVNROOT variable so that I do not have to type it every time I for example, need to checkout a new project.
There is no equivalent of CVSROOT in Subversion. But when it has been asked for before, the response has been: what do you need it for? If you just want a shortcut for checking out, define an environment variable and use that. This is what I do in my ~/.bashrc:
Then I can for example:
svn checkout $M/trunk/dports
svn log $M --limit 5
I use the variable "M" because it's easy to remember that it stands for MacPorts and I'm not using it for anything else, but you can name it anything you want, or define multiple env vars for multiple repositories or multiple paths within a repository (for example, a separate variable for the trunk, or for a deep path within the repo that you often want to refer to).
Remember, the working copy stores the repository URL it was checked out from, so the only time you need the repository URL is when you're checking out or when you're asking for a log or similar function and aren't already sitting in the working copy's directory.
This is an archived mail posted to the Subversion Users mailing list.