1
0
Fork 0

Update SvnDownloader.php

pull/2825/head
Sebastian Brandt 2014-03-28 16:27:00 +01:00
parent 16489dc084
commit f633ab503e
1 changed files with 6 additions and 1 deletions

View File

@ -47,8 +47,13 @@ class SvnDownloader extends VcsDownloader
throw new \RuntimeException('The .svn directory is missing from '.$path.', see http://getcomposer.org/commit-deps for more information'); throw new \RuntimeException('The .svn directory is missing from '.$path.', see http://getcomposer.org/commit-deps for more information');
} }
$ignoreAncestryCommand = "";
if ((int)$this->process->execute("svn --version | egrep 'version [0-9\.]+' -o | tr -d 'version .'") >= 170) {
$ignoreAncestryCommand = " --ignore-ancestry";
}
$this->io->write(" Checking out " . $ref); $this->io->write(" Checking out " . $ref);
$this->execute($url, "svn switch --ignore-ancestry", sprintf("%s/%s", $url, $ref), $path); $this->execute($url, "svn switch" . $ignoreAncestry, sprintf("%s/%s", $url, $ref), $path);
} }
/** /**