Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14033215
D7427.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D7427.id.diff
View Options
Index: src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php
===================================================================
--- src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php
+++ src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php
@@ -128,7 +128,8 @@
if (!$no_discovery) {
// TODO: It would be nice to discover only if we pulled something,
- // but this isn't totally trivial.
+ // but this isn't totally trivial. It's slightly more complicated
+ // with hosted repositories, too.
$lock_name = get_class($this).':'.$callsign;
$lock = PhabricatorGlobalLock::newLock($lock_name);
Index: src/applications/repository/engine/PhabricatorRepositoryEngine.php
===================================================================
--- src/applications/repository/engine/PhabricatorRepositoryEngine.php
+++ src/applications/repository/engine/PhabricatorRepositoryEngine.php
@@ -54,7 +54,8 @@
if ($this->getVerbose()) {
$console = PhutilConsole::getConsole();
$argv = func_get_args();
- call_user_func_array(array($console, 'writeLog'), $argv);
+ $argv[0] = $argv[0]."\n";
+ call_user_func_array(array($console, 'writeOut'), $argv);
}
return $this;
}
Index: src/applications/repository/engine/PhabricatorRepositoryPullEngine.php
===================================================================
--- src/applications/repository/engine/PhabricatorRepositoryPullEngine.php
+++ src/applications/repository/engine/PhabricatorRepositoryPullEngine.php
@@ -25,6 +25,16 @@
$vcs = $repository->getVersionControlSystem();
$callsign = $repository->getCallsign();
+
+ if ($repository->isHosted()) {
+ $this->log(
+ pht(
+ 'Repository "%s" is hosted, so Phabricator does not pull updates '.
+ 'for it.',
+ $callsign));
+ return;
+ }
+
switch ($vcs) {
case PhabricatorRepositoryType::REPOSITORY_TYPE_SVN:
// We never pull a local copy of Subversion repositories.
Index: src/applications/repository/engine/__tests__/PhabricatorWorkingCopyTestCase.php
===================================================================
--- src/applications/repository/engine/__tests__/PhabricatorWorkingCopyTestCase.php
+++ src/applications/repository/engine/__tests__/PhabricatorWorkingCopyTestCase.php
@@ -45,7 +45,8 @@
$dir = PhutilDirectoryFixture::newFromArchive($path);
$local = new TempFile('.ignore');
- $repo = id(new PhabricatorRepository())
+ $user = $this->generateNewTestUser();
+ $repo = PhabricatorRepository::initializeNewRepository($user)
->setCallsign($callsign)
->setName(pht('Test Repo "%s"', $callsign))
->setVersionControlSystem($vcs_type)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 10, 5:05 PM (2 d, 7 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6734570
Default Alt Text
D7427.id.diff (2 KB)
Attached To
Mode
D7427: Don't pull updates for repositories marked as hosted
Attached
Detach File
Event Timeline
Log In to Comment