From 7fb465f247f42e31d0c338652786baaac0be5ae2 Mon Sep 17 00:00:00 2001 From: Zachary Eisinger Date: Fri, 4 Sep 2020 15:18:37 -0700 Subject: [PATCH] Set dotnet root for windows --- dist/index.js | 1 + src/installer.ts | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/dist/index.js b/dist/index.js index 089c091..dfd3eee 100644 --- a/dist/index.js +++ b/dist/index.js @@ -16779,6 +16779,7 @@ class DotnetCoreInstaller { if (IS_WINDOWS) { // This is the default set in install-dotnet.ps1 core.addPath(path.join(process.env['LocalAppData'] + '', 'Microsoft', 'dotnet')); + core.exportVariable('DOTNET_ROOT', path.join(process.env['LocalAppData'] + '', 'Microsoft', 'dotnet')); } else { // This is the default set in install-dotnet.sh diff --git a/src/installer.ts b/src/installer.ts index a573604..66032fc 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -169,6 +169,10 @@ export class DotnetCoreInstaller { core.addPath( path.join(process.env['LocalAppData'] + '', 'Microsoft', 'dotnet') ); + core.exportVariable( + 'DOTNET_ROOT', + path.join(process.env['LocalAppData'] + '', 'Microsoft', 'dotnet') + ); } else { // This is the default set in install-dotnet.sh core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));