fix: change from using env to os module

This commit is contained in:
Peng Xiao 2023-12-26 17:11:46 +08:00
parent 2c3ea16a59
commit 8454a14c98
No known key found for this signature in database
3 changed files with 14 additions and 10 deletions

2
dist/setup/index.js vendored
View file

@ -92567,7 +92567,7 @@ const restoreCache = (packageManager, cacheDependencyPath) => __awaiter(void 0,
if (!packageManagerInfo) {
throw new Error(`Caching for '${packageManager}' is not supported`);
}
const platform = process.env.RUNNER_OS;
const platform = os_1.default.platform();
const arch = os_1.default.arch();
const cachePaths = yield (0, cache_utils_1.getCacheDirectories)(packageManagerInfo, cacheDependencyPath);
core.saveState(constants_1.State.CachePaths, cachePaths);