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

Re: how to switch a WC back?

From: Daniel Becroft <djcbecroft_at_gmail.com>
Date: Mon, 14 Feb 2011 09:29:24 +1000

On Mon, Feb 14, 2011 at 9:15 AM, Paul Maier <svn-user_at_web.de> wrote:

> Hi,
>
> a question about how to switch back a WC:
>
> I checked out a WC, and then switched some subdirectories to some other
> directories. I worked with that for a while, checked in, all fine.
> Now I want to switch my WC back.
>
> Can I automatically "un-switch" the WC?
>
> I mean: I could do a second switch and there I could manually specify the
> URL of
> the original subdir. That would work, but would mean, that I manually find
> out:
> - which subdirectory is in a switched state
>

From 'svn help status':

    Fifth column: Whether the item is switched or a file external
      ' ' normal
      'S' the item has a Switched URL relative to the parent
      'X' a versioned file created by an eXternals definition

> - what is the URL of the unswitched directory (how??)
>

SVN does not store this information - you'd need to find this out for
yourself.

> - manually switch back.
>

svn switch old_url sub_dir?

> Is there a way to issue some command that does that for me automatically?
>

You can run switch on the parent directory (using the same URL as it
currently has), and this will override any switched sub-directories.

> Thanks for hints!
>
> Regards
> Paul

Cheers,
Daniel B.
Received on 2011-02-14 00:30:23 CET

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.