diff --git a/.github/workflows/workflow.yml b/.github/workflows/workflow.yml index f988061..80d6034 100644 --- a/.github/workflows/workflow.yml +++ b/.github/workflows/workflow.yml @@ -22,7 +22,7 @@ jobs: strategy: matrix: os: [ubuntu-latest, macOS-latest, windows-latest] - ghc: ['8.8.3'] + ghc: ['8.8.3', '8.4.4'] cabal: ['3.0.0.0'] include: - os: ubuntu-latest diff --git a/dist/index.js b/dist/index.js index 5d28383..6387c02 100644 --- a/dist/index.js +++ b/dist/index.js @@ -8661,9 +8661,7 @@ async function installTool(tool, version) { const cmd = ['choco', 'install', tool, '--version', version]; const flags = ['-m', '--no-progress', '-r']; await exec_1.exec('powershell', cmd.concat(flags)); - const t = `${tool}.${version}`; - const p = ['lib', t, 'tools', t, tool === 'ghc' ? 'bin' : '']; - core.addPath(path_1.join(process.env.ChocolateyInstall || '', ...p)); + core.addPath(path_1.join(process.env.ChocolateyInstall || '', 'lib', `${tool}.${version}`, 'tools', `${tool}-${version}`, tool === 'ghc' ? 'bin' : '')); } else { const ghcup = await tc.downloadTool('https://raw.githubusercontent.com/haskell/ghcup/master/ghcup'); diff --git a/src/installer.ts b/src/installer.ts index 1da5f8d..ab3a2e0 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -135,9 +135,16 @@ async function installTool(tool: Tool, version: string): Promise { const flags = ['-m', '--no-progress', '-r']; await exec('powershell', cmd.concat(flags)); - const t = `${tool}.${version}`; - const p = ['lib', t, 'tools', t, tool === 'ghc' ? 'bin' : '']; - core.addPath(join(process.env.ChocolateyInstall || '', ...p)); + core.addPath( + join( + process.env.ChocolateyInstall || '', + 'lib', + `${tool}.${version}`, + 'tools', + `${tool}-${version}`, + tool === 'ghc' ? 'bin' : '' + ) + ); } else { const ghcup = await tc.downloadTool( 'https://raw.githubusercontent.com/haskell/ghcup/master/ghcup'