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

Re: Tags and branches are NOT the same

From: Folker Schamel <schamel23_at_spinor.com>
Date: 2006-03-20 20:12:17 CET

Vincent Starre wrote:
> Folker Schamel wrote:
>
>> Vincent Starre wrote:
>>
>>> The only example I've heard is that of "I want to move a couple of
>>> files back to the state of the tag"
>>> Currently this is done with:
>>> svn merge -rBASE /path/to/origin/of/wc /path/to/tag/desired ./filename
>>
>>
>> Use "svn switch" instead of "svn merge".
>>
>> Cheers,
>> Folker
>
> Seem to have missed the point:
> 1) "switch" doesnt operate on single files. Adding this as a feature
> would be one way to help this out, but this would require implementation
> of "views", which I gather arent even on the radar. (in 1.2, attempting
> to switch a single file silently does nothing)
> 2) In 1.2, attempting to switch a single file using the syntax described
> above (replacing only "merge" with "switch", not changing the URLs to
> point to the individual file) is a great way to place your wc into an
> irreperable state. Try it, it's fun.
> These may both be bugs, but I do not have 1.3, so I can't try. If anyone
> else cares to attempt to reproduce, go ahead.

For me switching a single file with svn 1.3 works fine, see below.
If this was the only thing you missed in svn ... ;-)

Cheers,
Folker

*****

C:\temp\svntest>svn --version
svn, version 1.3.0 (r17949)
    compiled Jan 15 2006, 23:18:48

Copyright (C) 2000-2005 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).

The following repository access (RA) modules are available:

* ra_dav : Module for accessing a repository via WebDAV (DeltaV) protocol.
   - handles 'http' scheme
   - handles 'https' scheme
* ra_svn : Module for accessing a repository using the svn network protocol.
   - handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
   - handles 'file' scheme

C:\temp\svntest>svnadmin create repo

C:\temp\svntest>svn mkdir file:///temp/svntest/repo/trunk -m "Test"

Committed revision 1.

C:\temp\svntest>svn mkdir file:///temp/svntest/repo/branches -m "Test"

Committed revision 2.

C:\temp\svntest>svn checkout file:///temp/svntest/repo/trunk wc
Checked out revision 2.

C:\temp\svntest>cd wc

C:\temp\svntest\wc>echo >test1.txt

C:\temp\svntest\wc>echo >test2.txt

C:\temp\svntest\wc>svn add *.txt
A test1.txt
A test2.txt

C:\temp\svntest\wc>svn commit -m "Test"
Adding test1.txt
Adding test2.txt
Transmitting file data ..
Committed revision 3.

C:\temp\svntest\wc>svn copy file:///temp/svntest/repo/trunk file:///temp/svntest
/repo/branches/mybranch -m "Test"

Committed revision 4.

C:\temp\svntest\wc>svn switch file:///temp/svntest/repo/branches/mybranch/test2.
txt test2.txt
At revision 4.

C:\temp\svntest\wc>svn info *.txt
Path: test1.txt
Name: test1.txt
URL: file:///temp/svntest/repo/trunk/test1.txt
Repository Root: file:///temp/svntest/repo
Repository UUID: 37a7a4a0-f12b-d74e-9a15-f4722dea34df
Revision: 3
Node Kind: file
Schedule: normal
Last Changed Author: folker
Last Changed Rev: 3
Last Changed Date: 2006-03-20 20:05:56 +0100 (Mo, 20 Mrz 2006)
Text Last Updated: 2006-03-20 20:05:44 +0100 (Mo, 20 Mrz 2006)
Properties Last Updated: 2006-03-20 20:05:51 +0100 (Mo, 20 Mrz 2006)
Checksum: 284f1df5b7a038c43a31ec70907734ff

Path: test2.txt
Name: test2.txt
URL: file:///temp/svntest/repo/branches/mybranch/test2.txt
Repository Root: file:///temp/svntest/repo
Repository UUID: 37a7a4a0-f12b-d74e-9a15-f4722dea34df
Revision: 4
Node Kind: file
Schedule: normal
Last Changed Author: folker
Last Changed Rev: 3
Last Changed Date: 2006-03-20 20:05:56 +0100 (Mo, 20 Mrz 2006)
Text Last Updated: 2006-03-20 20:05:47 +0100 (Mo, 20 Mrz 2006)
Properties Last Updated: 2006-03-20 20:05:51 +0100 (Mo, 20 Mrz 2006)
Checksum: 284f1df5b7a038c43a31ec70907734ff

C:\temp\svntest\wc>svn switch file:///temp/svntest/repo/trunk
At revision 4.

C:\temp\svntest\wc>svn info *.txt
Path: test1.txt
Name: test1.txt
URL: file:///temp/svntest/repo/trunk/test1.txt
Repository Root: file:///temp/svntest/repo
Repository UUID: 37a7a4a0-f12b-d74e-9a15-f4722dea34df
Revision: 4
Node Kind: file
Schedule: normal
Last Changed Author: folker
Last Changed Rev: 3
Last Changed Date: 2006-03-20 20:05:56 +0100 (Mo, 20 Mrz 2006)
Text Last Updated: 2006-03-20 20:05:44 +0100 (Mo, 20 Mrz 2006)
Properties Last Updated: 2006-03-20 20:05:51 +0100 (Mo, 20 Mrz 2006)
Checksum: 284f1df5b7a038c43a31ec70907734ff

Path: test2.txt
Name: test2.txt
URL: file:///temp/svntest/repo/trunk/test2.txt
Repository Root: file:///temp/svntest/repo
Repository UUID: 37a7a4a0-f12b-d74e-9a15-f4722dea34df
Revision: 4
Node Kind: file
Schedule: normal
Last Changed Author: folker
Last Changed Rev: 3
Last Changed Date: 2006-03-20 20:05:56 +0100 (Mo, 20 Mrz 2006)
Text Last Updated: 2006-03-20 20:05:47 +0100 (Mo, 20 Mrz 2006)
Properties Last Updated: 2006-03-20 20:05:51 +0100 (Mo, 20 Mrz 2006)
Checksum: 284f1df5b7a038c43a31ec70907734ff

C:\temp\svntest\wc>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Mar 20 20:13:08 2006

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