Changeset View
Changeset View
Standalone View
Standalone View
src/workingcopy/ArcanistWorkingCopy.php
| <?php | <?php | ||||
| abstract class ArcanistWorkingCopy | abstract class ArcanistWorkingCopy | ||||
| extends Phobject { | extends Phobject { | ||||
| private $path; | private $path; | ||||
| private $workingDirectory; | private $workingDirectory; | ||||
| public static function newFromWorkingDirectory($path) { | public static function newFromWorkingDirectory($path) { | ||||
| $working_types = id(new PhutilClassMapQuery()) | $working_types = id(new PhutilClassMapQuery()) | ||||
| ->setParentClass(__CLASS__) | ->setAncestorClass(__CLASS__) | ||||
| ->execute(); | ->execute(); | ||||
| // Find the outermost directory which is under version control. We go from | // Find the outermost directory which is under version control. We go from | ||||
| // the top because: | // the top because: | ||||
| // | // | ||||
| // - This gives us a more reasonable behavior if you embed one repository | // - This gives us a more reasonable behavior if you embed one repository | ||||
| // inside another repository. | // inside another repository. | ||||
| // - This handles old Subversion working copies correctly. Before | // - This handles old Subversion working copies correctly. Before | ||||
| ▲ Show 20 Lines • Show All 76 Lines • Show Last 20 Lines | |||||