diff --git a/dist/index.js b/dist/index.js index bbe2c2b..8e20d7f 100644 --- a/dist/index.js +++ b/dist/index.js @@ -513,7 +513,7 @@ function run() { const installedDotnetVersions = []; const globalJsonFileInput = core.getInput('global-json-file'); if (globalJsonFileInput) { - const globalJsonPath = path_1.default.join(process.cwd(), globalJsonFileInput); + const globalJsonPath = path_1.default.resolve(process.cwd(), globalJsonFileInput); if (!fs.existsSync(globalJsonPath)) { throw new Error(`The specified global.json file '${globalJsonFileInput}' does not exist`); } diff --git a/src/setup-dotnet.ts b/src/setup-dotnet.ts index 119053a..31c80a2 100644 --- a/src/setup-dotnet.ts +++ b/src/setup-dotnet.ts @@ -31,7 +31,7 @@ export async function run() { const globalJsonFileInput = core.getInput('global-json-file'); if (globalJsonFileInput) { - const globalJsonPath = path.join(process.cwd(), globalJsonFileInput); + const globalJsonPath = path.resolve(process.cwd(), globalJsonFileInput); if (!fs.existsSync(globalJsonPath)) { throw new Error( `The specified global.json file '${globalJsonFileInput}' does not exist`