You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Neil Trodden <ne...@gmail.com> on 2009/04/01 17:09:31 UTC

Externals for a single file - usage?

The need to use external to bring in a single file to my working copies
arose today and fortunately this was implemented in 1.6 - which I've now
upgraded to.
The problem I have is that I still get an error when updating with my new
external property set. I'm using the same format I use for bringing in
external folders but perhaps I need to do something else? I'm afraid the
latest version of the svnbook only mentions that single file externals are
possible but no specifics on implementation.

I have a web application checked out as a working copy. From the root of
that checkout, I have a folder called Website/bin into which I wish to drop
a shared library file into. The bin folder itself is not in source control
but it's parent "Website" is.

So the file I want is:

svn://ls1/LVGSharedLibrary/tags/stable/LVGLibrary/bin/Release/LVGLibrary.dll
- which is a valid url - and it needs checking out into the folder
"Website\Bin" relative to my working copy

I've added the following line to properties for the root of my working copy:

svn://ls1/LVGSharedLibrary/tags/stable/LVGLibrary/bin/Release/LVGLibrary.dll
Website/Bin/LVGLibrary.dll

..and it fails.

Am I doing something wrong?


-- 
Neil Trodden

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].

Re: Externals for a single file - usage?

Posted by Neil Trodden <ne...@gmail.com>.
I'm not sure I understand. Do you mean don't add the external to the working
copy but do it directly in the repository?
(apologies for mailing bob directly, the default in gmail does that rather
than responds to the list)

2009/4/1 Bob Archer <Bo...@amsi.com>

>  From what I have read about the file level externals you need the project
> with the external in it check out in a WC and there is some client side
> stuff that goes on there.
>
>
>
> BOb
>
>
>
>
>   ------------------------------
>
> *From:* Neil Trodden [mailto:neil.trodden@gmail.com]
> *Sent:* Wednesday, April 01, 2009 1:10 PM
> *To:* users@subversion.tigris.org
> *Subject:* Externals for a single file - usage?
>
>
>
> The need to use external to bring in a single file to my working copies
> arose today and fortunately this was implemented in 1.6 - which I've now
> upgraded to.
>
>
>
> The problem I have is that I still get an error when updating with my new
> external property set. I'm using the same format I use for bringing in
> external folders but perhaps I need to do something else? I'm afraid the
> latest version of the svnbook only mentions that single file externals are
> possible but no specifics on implementation.
>
>
>
> I have a web application checked out as a working copy. From the root of
> that checkout, I have a folder called Website/bin into which I wish to drop
> a shared library file into. The bin folder itself is not in source control
> but it's parent "Website" is.
>
>
>
> So the file I want is:
>
>
>
> svn://ls1/LVGSharedLibrary/tags/stable/LVGLibrary/bin/Release/LVGLibrary.dll
> - which is a valid url - and it needs checking out into the folder
> "Website\Bin" relative to my working copy
>
>
>
> I've added the following line to properties for the root of my working
> copy:
>
>
>
> svn://ls1/LVGSharedLibrary/tags/stable/LVGLibrary/bin/Release/LVGLibrary.dll
> Website/Bin/LVGLibrary.dll
>
>
>
> ..and it fails.
>
>
>
> Am I doing something wrong?
>
>
>
>
> --
> Neil Trodden
>



-- 
Neil Trodden

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].

RE: Externals for a single file - usage?

Posted by Bob Archer <bo...@amsi.com>.
> I just don't understand this at all. I have a working copy of my
project checked out, I've also added the bin folder in my web project
into svn and it still doesn't work. Am I supposed to have a separate
checkout of my library on my machine and then put the url to *that* as
the path to the external? Surely the problem with that is that the path
on my machine will be different to the path needed for my co-workers and
we'll keep overwriting each others external properties when we check in?

 

Yes, you need the file you are referring to in the external to be in the
checked out working copy.

 

Here is what I did.

 

I have a working copy with:

 

ProjectName/Build/ccnetproject.xml

 

I want that file to be available at:

 

ProjectName/Product/Install

 

So, I add the following property to the Install folder:

 

svn:externals ../../Build/ccnetproject.xml ccnetproject.xml

 

Now, when I update the "Installs" folder the ccnetproject.xml file is
put into the installs folder as a versioned file. So,
ProjectName/Build/ccnetproject.xml needs to be checked out in the WC
where my file external is.

 

So, you can't refer to a file that is only in the repository. Why this
is? I know not. Seems like a limitation that would be nice if it were
lifted. But, it is there in this version.

 

I tried to create a file external that pointed to a file in a directory
external, but that didn't work. 

 

So, HTH,

BOb

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].

Re: Externals for a single file - usage?

Posted by Neil Trodden <ne...@gmail.com>.
"The path to the file external must be in a working copy that is already
checked out. While directory externals can place the external directory at
any depth and it will create any intermediate directories, file externals
must be placed into a working copy that is already checked out."
I just don't understand this at all. I have a working copy of my project
checked out, I've also added the bin folder in my web project into svn and
it still doesn't work. Am I supposed to have a separate checkout of my
library on my machine and then put the url to *that* as the path to the
external? Surely the problem with that is that the path on my machine will
be different to the path needed for my co-workers and we'll keep overwriting
each others external properties when we check in?


2009/4/1 Bob Archer <Bo...@amsi.com>

>  From the release notes:
>
>
>
> If the URL in a svn:externals description refers to a file, it will be
> added into the working copy as a versioned item.
>
> There are a few differences between directory and file externals.
>
>    - The path to the file external must be in a working copy that is
>    already checked out. While directory externals can place the external
>    directory at any depth and it will create any intermediate directories, file
>    externals must be placed into a working copy that is already checked out.
>    - The file external's URL must be in the same repository as the URL
>    that the file external will be inserted into; inter-repository file
>    externals are not supported.
>    - While commits do not descend into a directory external, a commit in a
>    directory containing a file external will commit any modifications to the
>    file external.
>
> The differences between a normal versioned file and a file external.
>
>    - File externals cannot be moved or deleted; the svn:externals property
>    must be modified instead; however, file externals can be copied.
>
> Other facts.
>
>    - A file external shows up as a X in the switched status column.
>
>
>
>
>   ------------------------------
>
> *From:* Neil Trodden [mailto:neil.trodden@gmail.com]
> *Sent:* Wednesday, April 01, 2009 4:26 PM
> *To:* Bob Archer
> *Subject:* Re: Externals for a single file - usage?
>
>
>
> I'm not sure I understand. Do you mean don't add the external to the
> working copy but do it directly in the repository?
>
> 2009/4/1 Bob Archer <Bo...@amsi.com>
>
> From what I have read about the file level externals you need the project
> with the external in it check out in a WC and there is some client side
> stuff that goes on there.
>
>
>
> BOb
>
>
>
>
>   ------------------------------
>
> *From:* Neil Trodden [mailto:neil.trodden@gmail.com]
> *Sent:* Wednesday, April 01, 2009 1:10 PM
> *To:* users@subversion.tigris.org
> *Subject:* Externals for a single file - usage?
>
>
>
> The need to use external to bring in a single file to my working copies
> arose today and fortunately this was implemented in 1.6 - which I've now
> upgraded to.
>
>
>
> The problem I have is that I still get an error when updating with my new
> external property set. I'm using the same format I use for bringing in
> external folders but perhaps I need to do something else? I'm afraid the
> latest version of the svnbook only mentions that single file externals are
> possible but no specifics on implementation.
>
>
>
> I have a web application checked out as a working copy. From the root of
> that checkout, I have a folder called Website/bin into which I wish to drop
> a shared library file into. The bin folder itself is not in source control
> but it's parent "Website" is.
>
>
>
> So the file I want is:
>
>
>
> svn://ls1/LVGSharedLibrary/tags/stable/LVGLibrary/bin/Release/LVGLibrary.dll
> - which is a valid url - and it needs checking out into the folder
> "Website\Bin" relative to my working copy
>
>
>
> I've added the following line to properties for the root of my working
> copy:
>
>
>
> svn://ls1/LVGSharedLibrary/tags/stable/LVGLibrary/bin/Release/LVGLibrary.dll
> Website/Bin/LVGLibrary.dll
>
>
>
> ..and it fails.
>
>
>
> Am I doing something wrong?
>
>
>
>
> --
> Neil Trodden
>
>
>
>
> --
> Neil Trodden
>



-- 
Neil Trodden

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].

RE: Externals for a single file - usage?

Posted by Bob Archer <bo...@amsi.com>.

Re: Externals for a single file - usage?

Posted by Neil Trodden <ne...@gmail.com>.
Thanks Ryan, but even if I add the bin folder that the file external should
appear under to svn, I still can't bring the external file in - I get the
error that it failed. I've seen those release notes (which are echoed in the
latest book version) but the first paragraph about externals doesn't seem
clear to me at all about what is required.
Perhaps I'm thinking about this the wrong way. The benefit of bringing the
dll in directly to other people's projects is that they are restricted to a
particular release. The alternative is that they all check our 'team
library' out as a working copy alongside all their other wcs and add
references to it relatively but I just *know* at some point someone will
check in changes to that library wc inadvertently. As much as I want to
trust people not to screw up, I really could do with a way of *just* giving
them the binary tagged 'release' in their own svn projects.

2009/4/2 Ryan Schmidt <su...@ryandesign.com>

> On Apr 1, 2009, at 12:09, Neil Trodden wrote:
>
>>  The bin folder itself is not in source control but it's parent "Website"
>> is.
>>
>
> That's the problem. For file-based externals, the folder in which the
> external item appears must be versioned.
>
> If the book doesn't yet describe this, consult the release notes:
>
> http://subversion.tigris.org/svn_1.6_releasenotes.html#externals
>
>


-- 
Neil Trodden

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].

Re: Externals for a single file - usage?

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Apr 1, 2009, at 12:09, Neil Trodden wrote:

> The need to use external to bring in a single file to my working  
> copies arose today and fortunately this was implemented in 1.6 -  
> which I've now upgraded to.
>
> The problem I have is that I still get an error when updating with  
> my new external property set. I'm using the same format I use for  
> bringing in external folders but perhaps I need to do something  
> else? I'm afraid the latest version of the svnbook only mentions  
> that single file externals are possible but no specifics on  
> implementation.
>
> I have a web application checked out as a working copy. From the  
> root of that checkout, I have a folder called Website/bin into  
> which I wish to drop a shared library file into. The bin folder  
> itself is not in source control but it's parent "Website" is.

That's the problem. For file-based externals, the folder in which the  
external item appears must be versioned.

If the book doesn't yet describe this, consult the release notes:

http://subversion.tigris.org/svn_1.6_releasenotes.html#externals

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].