mirror of
https://github.com/actions/setup-dotnet.git
synced 2025-04-08 08:19:57 +00:00
Add lib files
This commit is contained in:
@ -74,22 +74,6 @@ class DotnetCoreInstaller {
|
||||
}
|
||||
// Prepend the tools path. instructs the agent to prepend for future tasks
|
||||
core.addPath(toolPath);
|
||||
try {
|
||||
let globalToolPath = '';
|
||||
if (IS_WINDOWS) {
|
||||
globalToolPath = path.join(process.env.USERPROFILE || '', '.dotnet\\tools');
|
||||
}
|
||||
else {
|
||||
globalToolPath = path.join(process.env.HOME || '', '.dotnet/tools');
|
||||
}
|
||||
yield io.mkdirP(globalToolPath);
|
||||
core.addPath(globalToolPath);
|
||||
}
|
||||
catch (error) {
|
||||
//nop
|
||||
}
|
||||
// Set DOTNET_ROOT for dotnet core Apphost to find runtime since it is installed to a non well-known location.
|
||||
core.exportVariable('DOTNET_ROOT', toolPath);
|
||||
});
|
||||
}
|
||||
getLocalTool() {
|
||||
@ -137,7 +121,7 @@ class DotnetCoreInstaller {
|
||||
});
|
||||
}
|
||||
if (resultCode != 0) {
|
||||
throw `Failed to detect os with result code ${resultCode}`;
|
||||
throw `Failed to detect os with result code ${resultCode}. Output: ${output}`;
|
||||
}
|
||||
let index;
|
||||
if ((index = output.indexOf('Primary:')) >= 0) {
|
||||
@ -190,6 +174,7 @@ class DotnetCoreInstaller {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
let downloadUrls = [];
|
||||
let releasesJSON = yield this.getReleasesJson();
|
||||
core.debug('Releases: ' + releasesJSON);
|
||||
let releasesInfo = JSON.parse(yield releasesJSON.readBody());
|
||||
releasesInfo = releasesInfo.filter((releaseInfo) => {
|
||||
return (releaseInfo['version-sdk'] === version ||
|
||||
@ -285,7 +270,7 @@ class DotnetCoreInstaller {
|
||||
legacyUrlSearchString = 'dotnet-install: Legacy payload URL: ';
|
||||
}
|
||||
if (resultCode != 0) {
|
||||
throw `Failed to get download urls with result code ${resultCode}`;
|
||||
throw `Failed to get download urls with result code ${resultCode}. ${output}`;
|
||||
}
|
||||
let primaryUrl = '';
|
||||
let legacyUrl = '';
|
||||
|
Reference in New Issue
Block a user