mirror of
https://github.com/actions/setup-go.git
synced 2025-04-23 17:40:50 +00:00
fixup! Avoid Toolchain download before cache download
This commit is contained in:
parent
a02bf28b8a
commit
6a7d247afe
1 changed files with 5 additions and 2 deletions
|
@ -64,8 +64,11 @@ export async function run() {
|
||||||
const goPath = await io.which('go');
|
const goPath = await io.which('go');
|
||||||
// run `go version` with the bundled Go toolchain to avoid potentially
|
// run `go version` with the bundled Go toolchain to avoid potentially
|
||||||
// downloading one into the cache
|
// downloading one into the cache
|
||||||
const goVersion = (cp.execSync(`${goPath} version`) || '',
|
const goVersion = (
|
||||||
{env: {...process.env, GOTOOLCHAIN: 'local'}}).toString();
|
cp.execSync(`${goPath} version`, {
|
||||||
|
env: {...process.env, GOTOOLCHAIN: 'local'}
|
||||||
|
}) || ''
|
||||||
|
).toString();
|
||||||
|
|
||||||
if (cache && isCacheFeatureAvailable()) {
|
if (cache && isCacheFeatureAvailable()) {
|
||||||
const packageManager = 'default';
|
const packageManager = 'default';
|
||||||
|
|
Loading…
Add table
Reference in a new issue