diff --git a/dist/index.js b/dist/index.js index c9ca633..050c727 100644 --- a/dist/index.js +++ b/dist/index.js @@ -33002,6 +33002,7 @@ const core = __importStar(__nccwpck_require__(2186)); const exec = __importStar(__nccwpck_require__(1514)); const context_1 = __nccwpck_require__(8954); const cli_1 = __nccwpck_require__(6733); +const path_1 = __nccwpck_require__(1017); async function run() { try { const { workdir: cwd, command, token, installOnly } = (0, context_1.getInputs)(); @@ -33013,7 +33014,7 @@ async function run() { } await exec.exec(`${cliBinary} login --token=${token}`); core.debug(`Successfully logged to Square Cloud`); - core.addPath(cliBinary); + core.addPath((0, path_1.dirname)(cliBinary)); core.debug(`Added ${cliBinary} to path`); if (installOnly) return; diff --git a/src/index.ts b/src/index.ts index 2dfa2dd..0aef3d2 100644 --- a/src/index.ts +++ b/src/index.ts @@ -3,6 +3,7 @@ import * as exec from "@actions/exec"; import { getInputs } from "./context"; import { install } from "./cli"; +import { dirname } from "path"; async function run(): Promise { try { @@ -19,7 +20,7 @@ async function run(): Promise { await exec.exec(`${cliBinary} login --token=${token}`) core.debug(`Successfully logged to Square Cloud`) - core.addPath(cliBinary) + core.addPath(dirname(cliBinary)) core.debug(`Added ${cliBinary} to path`) if (installOnly) return