diff --git a/dist/index.js b/dist/index.js index c981d8b..0e88015 100644 --- a/dist/index.js +++ b/dist/index.js @@ -463,7 +463,6 @@ class DotnetCoreInstaller { } } exports.DotnetCoreInstaller = DotnetCoreInstaller; -DotnetCoreInstaller.addToPath = DotnetInstallDir.addToPath; (() => { DotnetInstallDir.setEnvironmentVariable(); })(); @@ -571,7 +570,7 @@ function run() { const installedVersion = yield dotnetInstaller.installDotnet(); installedDotnetVersions.push(installedVersion); } - installer_1.DotnetCoreInstaller.addToPath(); + installer_1.DotnetInstallDir.addToPath(); } const sourceUrl = core.getInput('source-url'); const configFile = core.getInput('config-file'); diff --git a/src/installer.ts b/src/installer.ts index 894d714..ec46528 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -246,8 +246,6 @@ export abstract class DotnetInstallDir { } export class DotnetCoreInstaller { - static addToPath = DotnetInstallDir.addToPath; - static { DotnetInstallDir.setEnvironmentVariable(); } diff --git a/src/setup-dotnet.ts b/src/setup-dotnet.ts index 58de8ef..ec1618b 100644 --- a/src/setup-dotnet.ts +++ b/src/setup-dotnet.ts @@ -1,5 +1,5 @@ import * as core from '@actions/core'; -import {DotnetCoreInstaller} from './installer'; +import {DotnetCoreInstaller, DotnetInstallDir} from './installer'; import * as fs from 'fs'; import path from 'path'; import semver from 'semver'; @@ -69,7 +69,7 @@ export async function run() { const installedVersion = await dotnetInstaller.installDotnet(); installedDotnetVersions.push(installedVersion); } - DotnetCoreInstaller.addToPath(); + DotnetInstallDir.addToPath(); } const sourceUrl: string = core.getInput('source-url');