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

Re: Pulling down (checking out or exporting) a single file from a rep ository?

From: William Nagel <bill_at_stagelogic.com>
Date: 2005-01-18 18:44:54 CET

On Jan 17, 2005, at 5:54 PM, Peter Valdemar Mørch wrote:

> jim.mochel@ascentialsoftware.com wrote:
>> But to do that I need to pull down single files
>> from an entire repository. Is there anyway to do this from the
>> command line or C libraries ?
> You can "export" a single file with:
> svn cat http://server/repos/path/file.ext > file.ext
> that will get you file.ext only.
> But you cannot use this to make modifications to file.ext and then
> commit your changes back to the repository. For that you need a
> working copy, and the finest granularity for that is a directory -
> you'll need to check out the entire directory as in:
> svn cat http://server/repos/path/

I think you meant "svn checkout" not "svn cat"

> vi path/file.ext
> svn ci -m "Changed foo to bar" file.ext
> As a workaround, you could of course organize your repository so there
> is one file pr. directory...

If you need to have the files exist somewhere that can't be a working
copy but also need to make changes that will be committed back to the
repository, you might be able to checkout a working copy somewhere else
on the filesystem and then make a symlink from the location where the
file is expected to exist.


To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Jan 18 18:47:26 2005

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