fix: revert main script path changes

This commit is contained in:
Nogic 2023-04-27 01:52:39 +00:00
parent d958ca3660
commit 3025f77b29
5 changed files with 8 additions and 8 deletions

View File

@ -22,12 +22,12 @@ inputs:
required: false
default: false
outputs:
cache-hit:
cache-hit:
description: 'A boolean value to indicate if a cache was hit.'
dotnet-version:
description: 'Contains the installed by action .NET SDK version for reuse.'
runs:
using: 'node16'
main: 'dist/setup/index.js'
main: 'dist/index.js'
post: 'dist/cache-save/index.js'
post-if: success()

View File

@ -71288,7 +71288,7 @@ class DotnetCoreInstaller {
];
const scriptName = utils_1.IS_WINDOWS ? 'install-dotnet.ps1' : 'install-dotnet.sh';
const escapedScript = path_1.default
.join(__dirname, '..', '..', 'externals', scriptName)
.join(__dirname, '..', 'externals', scriptName)
.replace(/'/g, "''");
let scriptArguments;
let scriptPath = '';
@ -71496,7 +71496,7 @@ function run() {
else {
core.setOutput(constants_1.Outputs.CacheHit, false);
}
const matchersPath = path_1.default.join(__dirname, '..', '..', '.github');
const matchersPath = path_1.default.join(__dirname, '..', '.github');
core.info(`##[add-matcher]${path_1.default.join(matchersPath, 'csc.json')}`);
}
catch (error) {

View File

@ -3,9 +3,9 @@
"version": "3.0.2",
"private": true,
"description": "setup dotnet action",
"main": "dist/setup/index.js",
"main": "dist/index.js",
"scripts": {
"build": "ncc build -o dist/setup src/setup-dotnet.ts && ncc build -o dist/cache-save src/cache-save.ts",
"build": "ncc build src/setup-dotnet.ts && ncc build -o dist/cache-save src/cache-save.ts",
"format": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --write \"**/*.{ts,yml,yaml}\"",
"format-check": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --check \"**/*.{ts,yml,yaml}\"",
"lint": "eslint --config ./.eslintrc.js \"**/*.ts\"",

View File

@ -188,7 +188,7 @@ export class DotnetCoreInstaller {
];
const scriptName = IS_WINDOWS ? 'install-dotnet.ps1' : 'install-dotnet.sh';
const escapedScript = path
.join(__dirname, '..', '..', 'externals', scriptName)
.join(__dirname, '..', 'externals', scriptName)
.replace(/'/g, "''");
let scriptArguments: string[];
let scriptPath = '';

View File

@ -101,7 +101,7 @@ export async function run() {
core.setOutput(Outputs.CacheHit, false);
}
const matchersPath = path.join(__dirname, '..', '..', '.github');
const matchersPath = path.join(__dirname, '..', '.github');
core.info(`##[add-matcher]${path.join(matchersPath, 'csc.json')}`);
} catch (error) {
core.setFailed(error.message);