From b3e022cb6894d63968104831b5d045e11a978520 Mon Sep 17 00:00:00 2001 From: Wojciech Mazur Date: Wed, 29 Jan 2025 13:13:56 +0100 Subject: [PATCH] Fix choco release --- .github/workflows/publish-chocolatey.yml | 3 +-- .github/workflows/releases.yml | 2 +- .github/workflows/test-chocolatey.yml | 8 +++++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish-chocolatey.yml b/.github/workflows/publish-chocolatey.yml index 3b31728a50ba..eef550e9d2f7 100644 --- a/.github/workflows/publish-chocolatey.yml +++ b/.github/workflows/publish-chocolatey.yml @@ -35,5 +35,4 @@ jobs: with: name: scala.nupkg - name: Publish the package to Chocolatey - run: choco push scala.nupkg --source https://push.chocolatey.org/ --api-key ${{ secrets.API-KEY }} - \ No newline at end of file + run: choco push scala.${{inputs.version}}.nupkg --source https://push.chocolatey.org/ --api-key ${{ secrets.API-KEY }} diff --git a/.github/workflows/releases.yml b/.github/workflows/releases.yml index 03ff19444d2f..bf1f4ca12a1c 100644 --- a/.github/workflows/releases.yml +++ b/.github/workflows/releases.yml @@ -25,7 +25,7 @@ permissions: jobs: publish-sdkman: - runs-on: [self-hosted, Linux] + runs-on: ubuntu-latest container: image: lampepfl/dotty:2021-03-22 options: --cpu-shares 4096 diff --git a/.github/workflows/test-chocolatey.yml b/.github/workflows/test-chocolatey.yml index b6ca9bf74b12..15aa10e5108e 100644 --- a/.github/workflows/test-chocolatey.yml +++ b/.github/workflows/test-chocolatey.yml @@ -21,7 +21,10 @@ on: env: CHOCOLATEY-REPOSITORY: chocolatey-pkgs - DOTTY_CI_INSTALLATION: ${{ secrets.GITHUB_TOKEN }} + # Controls behaviour of chocolatey{Install,Uninstall}.ps1 scripts + # During snapshot releases it uses a different layout and requires access token to GH Actions artifacts + # During stable releases it uses publically available archives + DOTTY_CI_INSTALLATION: ${{ endsWith(inputs.version, '-SNAPSHOT') && secrets.GITHUB_TOKEN || '' }} jobs: test: @@ -47,5 +50,4 @@ jobs: - name : Test the `scaladoc` command run : scaladoc --version - name : Uninstall the `scala` package - run : choco uninstall scala - \ No newline at end of file + run : choco uninstall scala \ No newline at end of file