From 3c3ae71c2694f92df7f862be5e755c7c3ddf9933 Mon Sep 17 00:00:00 2001 From: Dylan Ratcliffe Date: Sat, 16 Mar 2024 13:55:08 +0000 Subject: [PATCH] Adde release task --- .github/workflows/release.yaml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .github/workflows/release.yaml diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 0000000..2aaf67e --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,24 @@ +name: Publish Gem + +on: + workflow_dispatch: +jobs: + build: + runs-on: ubuntu-latest + permissions: + contents: write + + steps: + - uses: actions/checkout@v3 + + - uses: ruby/setup-ruby@v1 + with: + bundler-cache: true # runs 'bundle install' and caches installed gems automatically + + - name: Release Gem + if: contains(github.ref, 'refs/tags/v') + uses: cadwallion/publish-rubygems-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUBYGEMS_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }} + RELEASE_COMMAND: bundle exec rake release \ No newline at end of file