Skip to content

Commit

Permalink
Run zbctl in bash to enable globs
Browse files Browse the repository at this point in the history
  • Loading branch information
lenaschoenburg committed Oct 25, 2021
1 parent 073d342 commit a9ad30a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
5 changes: 1 addition & 4 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,7 @@ try {
await _actions_exec__WEBPACK_IMPORTED_MODULE_3__.exec(`ls ${path__WEBPACK_IMPORTED_MODULE_4__.dirname(binPath)}`);
console.log(`Making zbctl (${binPath}) available`);
_actions_core__WEBPACK_IMPORTED_MODULE_0__.addPath(path__WEBPACK_IMPORTED_MODULE_4__.dirname(binPath));
const output = await _actions_exec__WEBPACK_IMPORTED_MODULE_3__.getExecOutput(`zbctl ${command}`);
if (output.exitCode != 0) {
_actions_core__WEBPACK_IMPORTED_MODULE_0__.setFailed(`zbctl failed with exit code ${output.exitCode}: ${output.stderr}`);
}
const output = await _actions_exec__WEBPACK_IMPORTED_MODULE_3__.getExecOutput(`bash -c "zbctl ${command}"`);
_actions_core__WEBPACK_IMPORTED_MODULE_0__.setOutput("result", output.stdout);
} catch (error) {
_actions_core__WEBPACK_IMPORTED_MODULE_0__.setFailed(error.message);
Expand Down
5 changes: 1 addition & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,7 @@ try {
await exec.exec(`ls ${path.dirname(binPath)}`);
console.log(`Making zbctl (${binPath}) available`);
core.addPath(path.dirname(binPath));
const output = await exec.getExecOutput(`zbctl ${command}`);
if (output.exitCode != 0) {
core.setFailed(`zbctl failed with exit code ${output.exitCode}: ${output.stderr}`);
}
const output = await exec.getExecOutput(`bash -c "zbctl ${command}"`);
core.setOutput("result", output.stdout);
} catch (error) {
core.setFailed(error.message);
Expand Down

0 comments on commit a9ad30a

Please sign in to comment.