Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 26 additions & 17 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,32 @@
name: Trigger Nurax build
name: Release Gem
on:
workflow_dispatch:
release:
types: [released]
push:
tags:
- hyrax-v*

jobs:
trigger:
push:
if: github.repository == 'samvera/hyrax'
name: Push gem to RubyGems.org
runs-on: ubuntu-latest

permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
contents: write # IMPORTANT: this permission is required for `rake release` to push the release tag

environment: release

steps:
- id: latest-release
uses: pozetroninc/github-action-get-latest-release@v0.7.0
with:
repository: ${{ github.repository }}
token: ${{ github.token }}
excludes: prerelease, draft
- uses: peter-evans/repository-dispatch@v2.1.1
if: ${{ steps.latest-release.outputs.release == github.ref_name }}
with:
token: ${{ secrets.NURAX_ACCESS_TOKEN }}
event-type: release
repository: samvera-labs/nurax
client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}"}'
# Set up
- uses: actions/checkout@v5
with:
persist-credentials: false
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
ruby-version: ruby

# Release
- uses: rubygems/release-gem@v1
Loading