fix: path patch (#1162)

This commit is contained in:
Ludovic Fernandez
2025-02-10 15:33:29 +01:00
committed by GitHub
parent d9c129682c
commit b85ce4ff0a
3 changed files with 12 additions and 12 deletions

8
dist/post_run/index.js generated vendored
View File

@ -93982,7 +93982,7 @@ async function prepareEnv() {
const binPath = await prepareLint();
const patchPath = await fetchPatch();
core.info(`Prepared env in ${Date.now() - startedAt}ms`);
return { binPath: binPath, patchPath };
return { binPath, patchPath };
}
const printOutput = (res) => {
if (res.stdout) {
@ -93992,10 +93992,10 @@ const printOutput = (res) => {
core.info(res.stderr);
}
};
async function runLint(lintPath, patchPath) {
async function runLint(binPath, patchPath) {
const debug = core.getInput(`debug`);
if (debug.split(`,`).includes(`cache`)) {
const res = await execShellCommand(`${lintPath} cache status`);
const res = await execShellCommand(`${binPath} cache status`);
printOutput(res);
}
let userArgs = core.getInput(`args`);
@ -94068,7 +94068,7 @@ async function runLint(lintPath, patchPath) {
}
cmdArgs.cwd = path.resolve(workingDirectory);
}
const cmd = `${lintPath} run ${addedArgs.join(` `)} ${userArgs}`.trimEnd();
const cmd = `${binPath} run ${addedArgs.join(` `)} ${userArgs}`.trimEnd();
core.info(`Running [${cmd}] in [${cmdArgs.cwd || process.cwd()}] ...`);
const startedAt = Date.now();
try {

8
dist/run/index.js generated vendored
View File

@ -93982,7 +93982,7 @@ async function prepareEnv() {
const binPath = await prepareLint();
const patchPath = await fetchPatch();
core.info(`Prepared env in ${Date.now() - startedAt}ms`);
return { binPath: binPath, patchPath };
return { binPath, patchPath };
}
const printOutput = (res) => {
if (res.stdout) {
@ -93992,10 +93992,10 @@ const printOutput = (res) => {
core.info(res.stderr);
}
};
async function runLint(lintPath, patchPath) {
async function runLint(binPath, patchPath) {
const debug = core.getInput(`debug`);
if (debug.split(`,`).includes(`cache`)) {
const res = await execShellCommand(`${lintPath} cache status`);
const res = await execShellCommand(`${binPath} cache status`);
printOutput(res);
}
let userArgs = core.getInput(`args`);
@ -94068,7 +94068,7 @@ async function runLint(lintPath, patchPath) {
}
cmdArgs.cwd = path.resolve(workingDirectory);
}
const cmd = `${lintPath} run ${addedArgs.join(` `)} ${userArgs}`.trimEnd();
const cmd = `${binPath} run ${addedArgs.join(` `)} ${userArgs}`.trimEnd();
core.info(`Running [${cmd}] in [${cmdArgs.cwd || process.cwd()}] ...`);
const startedAt = Date.now();
try {

View File

@ -156,7 +156,7 @@ async function prepareEnv(): Promise<Env> {
core.info(`Prepared env in ${Date.now() - startedAt}ms`)
return { binPath: binPath, patchPath }
return { binPath, patchPath }
}
type ExecRes = {
@ -173,10 +173,10 @@ const printOutput = (res: ExecRes): void => {
}
}
async function runLint(lintPath: string, patchPath: string): Promise<void> {
async function runLint(binPath: string, patchPath: string): Promise<void> {
const debug = core.getInput(`debug`)
if (debug.split(`,`).includes(`cache`)) {
const res = await execShellCommand(`${lintPath} cache status`)
const res = await execShellCommand(`${binPath} cache status`)
printOutput(res)
}
@ -266,7 +266,7 @@ async function runLint(lintPath: string, patchPath: string): Promise<void> {
cmdArgs.cwd = path.resolve(workingDirectory)
}
const cmd = `${lintPath} run ${addedArgs.join(` `)} ${userArgs}`.trimEnd()
const cmd = `${binPath} run ${addedArgs.join(` `)} ${userArgs}`.trimEnd()
core.info(`Running [${cmd}] in [${cmdArgs.cwd || process.cwd()}] ...`)