diff --git a/scripts/arcanist.php b/scripts/arcanist.php index 6669b0b29..36be10531 100755 --- a/scripts/arcanist.php +++ b/scripts/arcanist.php @@ -522,9 +522,7 @@ function arcanist_load_libraries( if ($must_load) { throw new ArcanistUsageException($error); } else { - file_put_contents( - 'php://stderr', - phutil_console_wrap('WARNING: '.$error."\n\n")); + fwrite(STDERR, phutil_console_wrap('WARNING: '.$error."\n\n")); } } catch (PhutilLibraryConflictException $ex) { if ($ex->getLibrary() != 'arcanist') { diff --git a/src/parser/ArcanistBaseCommitParser.php b/src/parser/ArcanistBaseCommitParser.php index e226b3340..a6a893183 100644 --- a/src/parser/ArcanistBaseCommitParser.php +++ b/src/parser/ArcanistBaseCommitParser.php @@ -48,7 +48,7 @@ private function tokenizeBaseCommitSpecification($raw_spec) { private function log($message) { if ($this->verbose) { - file_put_contents('php://stderr', $message."\n"); + fwrite(STDERR, $message."\n"); } } diff --git a/src/workflow/ArcanistBaseWorkflow.php b/src/workflow/ArcanistBaseWorkflow.php index 15031923c..ef21792e5 100644 --- a/src/workflow/ArcanistBaseWorkflow.php +++ b/src/workflow/ArcanistBaseWorkflow.php @@ -1097,7 +1097,7 @@ public function writeLocalArcConfig(array $config) { * @return void */ protected function writeStatusMessage($msg) { - file_put_contents('php://stderr', $msg); + fwrite(STDERR, $msg); } protected function isHistoryImmutable() { diff --git a/src/workflow/ArcanistDiffWorkflow.php b/src/workflow/ArcanistDiffWorkflow.php index 1f9fabd9a..1eda21187 100644 --- a/src/workflow/ArcanistDiffWorkflow.php +++ b/src/workflow/ArcanistDiffWorkflow.php @@ -775,7 +775,7 @@ protected function generateChanges() { if ($is_raw) { if ($this->getArgument('raw')) { - file_put_contents('php://stderr', "Reading diff from stdin...\n"); + fwrite(STDERR, "Reading diff from stdin...\n"); $raw_diff = file_get_contents('php://stdin'); } else if ($this->getArgument('raw-command')) { list($raw_diff) = execx($this->getArgument('raw-command'));