From 0c50b6d2f65429a96d8c4763e54ca04c23b4a128 Mon Sep 17 00:00:00 2001 From: Brandon Chinn Date: Thu, 13 Jul 2023 21:09:52 -0700 Subject: [PATCH] Upgrade ghcup in windows --- dist/index.js | 1 + lib/installer.js | 1 + src/installer.ts | 1 + 3 files changed, 3 insertions(+) diff --git a/dist/index.js b/dist/index.js index fbb83c3..d5eaf7c 100644 --- a/dist/index.js +++ b/dist/index.js @@ -13556,6 +13556,7 @@ async function choco(tool, version) { async function ghcupBin(os) { core.debug(`ghcupBin : ${os}`); if (os === 'win32') { + await exec('ghcup', ['upgrade']); return 'ghcup'; } const cachedBin = tc.find('ghcup', opts_1.ghcup_version); diff --git a/lib/installer.js b/lib/installer.js index a42db22..19b2665 100644 --- a/lib/installer.js +++ b/lib/installer.js @@ -275,6 +275,7 @@ async function choco(tool, version) { async function ghcupBin(os) { core.debug(`ghcupBin : ${os}`); if (os === 'win32') { + await exec('ghcup', ['upgrade']); return 'ghcup'; } const cachedBin = tc.find('ghcup', opts_1.ghcup_version); diff --git a/src/installer.ts b/src/installer.ts index ca1296b..c0dd727 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -306,6 +306,7 @@ async function choco(tool: Tool, version: string): Promise { async function ghcupBin(os: OS): Promise { core.debug(`ghcupBin : ${os}`); if (os === 'win32') { + await exec('ghcup', ['upgrade']); return 'ghcup'; } const cachedBin = tc.find('ghcup', ghcup_version);