Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F13960787
D19693.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D19693.diff
View Options
diff --git a/support/ArcanistRuntime.php b/support/ArcanistRuntime.php
--- a/support/ArcanistRuntime.php
+++ b/support/ArcanistRuntime.php
@@ -3,9 +3,14 @@
final class ArcanistRuntime {
public function execute(array $argv) {
- $err = $this->checkEnvironment();
- if ($err) {
- return $err;
+
+ try {
+ $this->checkEnvironment();
+ } catch (Exception $ex) {
+ echo "CONFIGURATION ERROR\n\n";
+ echo $ex->getMessage();
+ echo "\n\n";
+ return 1;
}
PhutilTranslator::getInstance()
@@ -109,7 +114,8 @@
'minimum supported version ("%s"). Update PHP to continue.',
$cur_version,
$min_version);
- return $this->fatalError($message);
+
+ throw new Exception($message);
}
if ($is_windows) {
@@ -190,17 +196,9 @@
$problems[] = "PHP was built with this configure command:\n\n{$config}";
}
$problems = implode("\n\n", $problems);
- return $this->fatalError($problems);
- }
- return 0;
- }
-
- private function fatalError($message) {
- echo "CONFIGURATION ERROR\n\n";
- echo $message;
- echo "\n\n";
- return 1;
+ throw new Exception($problems);
+ }
}
private function loadConfiguration(PhutilArgumentParser $args) {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Oct 16, 1:23 AM (3 w, 2 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6715299
Default Alt Text
D19693.diff (1 KB)
Attached To
Mode
D19693: [Wilds] Slightly simplify fatal handling during "arc" setup
Attached
Detach File
Event Timeline
Log In to Comment