[line 144]
Subversion Switch command manager class
Update the working copy to a different URL.
From 'svn switch --help':
usage: 1. switch URL [PATH] 2. switch --relocate FROM TO [PATH...]
- Update the working copy to mirror a new URL within the repository.
This behaviour is similar to 'svn update', and is the way to
move a working copy to a branch or tag within the same repository.
2. Rewrite working copy URL metadata to reflect a syntactic change only. This is used when repository's root URL changes (such as a schema or hostname change) but your working copy still reflects the same directory within the same repository.
Conversion of the above usage example to VersionControl_SVN_Switch:
<?php
require_once 'VersionControl/SVN.php';
// Set up runtime options. Will be passed to all
// subclasses.
$switches = array('relocate' => 'true');
$args = array(
'svn://svn.example.com/repos/TestProj/trunk',
'svn://svn.example.com/repos/TestProj_Fork/trunk',
'/path/to/working/copy'
);
try {
}
?>
$switches is an array containing one or more command line options defined by the following associative keys:
$switches = array(
'r [revision]' => 'ARG (some commands also take ARG1:ARG2 range)
A revision argument can be one of:
NUMBER revision number
"{" DATE "}" revision at start of the date
"HEAD" latest in repository
"BASE" base rev of item's working
copy
"COMMITTED" last commit at or before BASE
"PREV" revision just before COMMITTED',
// either 'r' or 'revision' may be used
'N' => true|false,
// operate on single directory only
'non-recursive' => true|false,
// operate on single directory only
'q [quiet]' => true|false,
// print as little as possible
'diff3-cmd' => 'ARG',
// use ARG as merge command
'relocate' => true|false,
// relocate via URL-rewriting
'username' => 'Subversion repository login
',
'no-auth-cache' => true|false,
// Do not cache authentication tokens
'config-
dir' => 'Path to a Subversion configuration directory'
);
Note: Subversion does not offer an XML output option for this subcommand
The non-interactive option available on the command-line svn client may also be set (true|false), but it is set to true by default.