Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing GHC is slow. Possibly use cache? #52

Open
UlyssesZh opened this issue Nov 6, 2023 · 1 comment
Open

Installing GHC is slow. Possibly use cache? #52

UlyssesZh opened this issue Nov 6, 2023 · 1 comment

Comments

@UlyssesZh
Copy link

Installing GHC is slow. Is it possible to utilize caches if the versions of ghcup and cabal to be installed are exactly the one already installed before?

@unhammer
Copy link

I'd like to do this too. I saw commercialhaskell/stack#5754 (comment) claim to be able to cache ghcup ghc's, but when I tried something like that on windows-latest with

  - name: Cache GHC installation
    uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
    id: ghcup
    with:
      path: |
        C:\tools\${{ env.GHC_VERSION }}
        C:\ghcup\bin\*
        C:\ghcup\cache\*
        C:\ghcup\config.yaml
        C:\ghcup\ghc\${{ env.GHC_VERSION }}
      key: ghcup--${{ env.GHC_VERSION }}

I see

  Attempting to access tool ghc at location C:/ghcup/bin
  Succeeded accessing tool ghc at location C:/ghcup/bin
  C:\ghcup\bin\ghcup.exe set ghc 9.2.8
  [ Warn  ] New GHCup version available: 0.1.40.0. To upgrade, run 'ghcup upgrade'
  [ Info  ] verifying digest of: gs.exe
  [ Error ] [�
  C:\ghcup\bin\ghcup.exe unset ghc
  [ Info  ] verifying digest of: gs.exe
  [ Info  ] GHC successfully unset
  Attempting to install ghc 9.2.8 using chocolatey
  ::stop-commands::***
  C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe choco install ghc --version 9.2.8 --allow-multiple-versions --ignore-dependencies --no-progress --limit-output
  Installing the following packages:
  ghc
  By installing, you accept licenses for the packages.
  Downloading package from source 'https://community.chocolatey.org/api/v2/'

as if it's there, but not verified, or something like that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants