Differential D21373 Diff 50896 src/applications/repository/engine/PhabricatorRepositoryDiscoveryEngine.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/repository/engine/PhabricatorRepositoryDiscoveryEngine.php
| Show First 20 Lines • Show All 284 Lines • ▼ Show 20 Lines | list($xml) = $repository->execxRemoteCommand( | ||||
| $repository->getSubversionPathURI()); | $repository->getSubversionPathURI()); | ||||
| $xml = phutil_utf8ize($xml); | $xml = phutil_utf8ize($xml); | ||||
| $xml = new SimpleXMLElement($xml); | $xml = new SimpleXMLElement($xml); | ||||
| $remote_root = (string)($xml->entry[0]->repository[0]->root[0]); | $remote_root = (string)($xml->entry[0]->repository[0]->root[0]); | ||||
| $expect_root = $repository->getSubversionPathURI(); | $expect_root = $repository->getSubversionPathURI(); | ||||
| $normal_type_svn = PhabricatorRepositoryURINormalizer::TYPE_SVN; | $normal_type_svn = ArcanistRepositoryURINormalizer::TYPE_SVN; | ||||
| $remote_normal = id(new PhabricatorRepositoryURINormalizer( | $remote_normal = id(new ArcanistRepositoryURINormalizer( | ||||
| $normal_type_svn, | $normal_type_svn, | ||||
| $remote_root))->getNormalizedPath(); | $remote_root))->getNormalizedPath(); | ||||
| $expect_normal = id(new PhabricatorRepositoryURINormalizer( | $expect_normal = id(new ArcanistRepositoryURINormalizer( | ||||
| $normal_type_svn, | $normal_type_svn, | ||||
| $expect_root))->getNormalizedPath(); | $expect_root))->getNormalizedPath(); | ||||
| if ($remote_normal != $expect_normal) { | if ($remote_normal != $expect_normal) { | ||||
| throw new Exception( | throw new Exception( | ||||
| pht( | pht( | ||||
| 'Repository "%s" does not have a correctly configured remote URI. '. | 'Repository "%s" does not have a correctly configured remote URI. '. | ||||
| 'The remote URI for a Subversion repository MUST point at the '. | 'The remote URI for a Subversion repository MUST point at the '. | ||||
| ▲ Show 20 Lines • Show All 689 Lines • Show Last 20 Lines | |||||