mirror of https://github.com/actions/setup-go.git
Add changes before sync with upstream
This commit is contained in:
parent
2d0c507407
commit
07ecad3aa8
|
@ -3705,8 +3705,7 @@ function run() {
|
||||||
// stable will be true unless false is the exact input
|
// stable will be true unless false is the exact input
|
||||||
// since getting unstable versions should be explicit
|
// since getting unstable versions should be explicit
|
||||||
let stable = (core.getInput('stable') || 'true').toUpperCase() === 'TRUE';
|
let stable = (core.getInput('stable') || 'true').toUpperCase() === 'TRUE';
|
||||||
const cacheInput = core.getInput('cache');
|
const cache = core.getInput('cache');
|
||||||
const cache = cacheInput.toUpperCase() === 'TRUE' ? 'default' : cacheInput;
|
|
||||||
core.info(`Setup go ${stable ? 'stable' : ''} version spec ${versionSpec}`);
|
core.info(`Setup go ${stable ? 'stable' : ''} version spec ${versionSpec}`);
|
||||||
if (versionSpec) {
|
if (versionSpec) {
|
||||||
let token = core.getInput('token');
|
let token = core.getInput('token');
|
||||||
|
@ -3724,7 +3723,7 @@ function run() {
|
||||||
if (isGhes()) {
|
if (isGhes()) {
|
||||||
throw new Error('Caching is not supported on GHES');
|
throw new Error('Caching is not supported on GHES');
|
||||||
}
|
}
|
||||||
const packageManager = core.getInput('package-manager');
|
const packageManager = cache.toUpperCase() === 'TRUE' ? 'default' : cache;
|
||||||
const cacheDependencyPath = core.getInput('cache-dependency-path');
|
const cacheDependencyPath = core.getInput('cache-dependency-path');
|
||||||
yield cache_restore_1.restoreCache(packageManager, cacheDependencyPath);
|
yield cache_restore_1.restoreCache(packageManager, cacheDependencyPath);
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,7 +26,8 @@ const cachePackages = async () => {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const packageManager = cacheInput.toUpperCase() === 'TRUE' ? 'default' : cacheInput;
|
const packageManager =
|
||||||
|
cacheInput.toUpperCase() === 'TRUE' ? 'default' : cacheInput;
|
||||||
|
|
||||||
const state = core.getState(State.CacheMatchedKey);
|
const state = core.getState(State.CacheMatchedKey);
|
||||||
const primaryKey = core.getState(State.CachePrimaryKey);
|
const primaryKey = core.getState(State.CachePrimaryKey);
|
||||||
|
|
Loading…
Reference in New Issue