Skip to content

Commit

Permalink
Also ignore cd output from stdout (#86)
Browse files Browse the repository at this point in the history
In bash, `cd` will print the directory to stdout, so we also redirect
that output to /dev/null.
  • Loading branch information
jparise authored Mar 1, 2022
1 parent f0bc572 commit 9a287d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/GraphQLSchemaLinter.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public function getVersion() {
if (!empty($this->dependencyVersions)) {

foreach ($this->dependencyVersions as $name => $required) {
list($err, $dep_version, $stderr) = exec_manual('cd .arcanist 2>/dev/null && npm list --depth=0 2>/dev/null | grep "%C" | cut -d "@" -f 3 | tr -d "[:space:]"', $name);
list($err, $dep_version, $stderr) = exec_manual('cd .arcanist 2>&1 >/dev/null && npm list --depth=0 2>/dev/null | grep "%C" | cut -d "@" -f 3 | tr -d "[:space:]"', $name);

if (empty($version) || !$this->checkVersion($dep_version, $required)) {
$message = pht(
Expand Down

0 comments on commit 9a287d1

Please sign in to comment.