From 913c3d2fcd08ce8877c775189f571026fd68af36 Mon Sep 17 00:00:00 2001 From: Julien Richard-Foy Date: Fri, 29 Jan 2021 15:25:18 +0100 Subject: [PATCH] Enable cache in release action, and enable the action only on push tag --- .github/workflows/release.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ffaea8b..75f6018 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -2,15 +2,17 @@ name: Release on: push: branches: [master, main] - tags: ["*"] + tags: ["v*"] jobs: publish: + if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') runs-on: ubuntu-20.04 steps: - uses: actions/checkout@v2.3.4 with: fetch-depth: 0 - uses: olafurpg/setup-scala@v10 + - uses: coursier/cache-action@v5 - run: sbt ci-release env: PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}