Skip to content

Commit

Permalink
Use Rubygems Trusted Publishers to publish.
Browse files Browse the repository at this point in the history
This doesn't need to store any token in GitHub.
For more details: https://guides.rubygems.org/trusted-publishing/
  • Loading branch information
iMacTia committed Jan 20, 2024
1 parent cd2cdfd commit f86a588
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/publish.yml
Expand Up @@ -4,13 +4,15 @@ on:
release:
types: [published]

permissions:
contents: read # to checkout the code (actions/checkout)
jobs:
build:
name: Publish to Rubygems
runs-on: ubuntu-latest

permissions:
contents: write
id-token: write

steps:
- uses: actions/checkout@v4

Expand All @@ -20,6 +22,4 @@ jobs:
ruby-version: 3

- name: Publish to RubyGems
uses: dawidd6/action-publish-gem@v1
with:
api_key: ${{secrets.RUBYGEMS_AUTH_TOKEN}}
uses: rubygems/release-gem@v1

0 comments on commit f86a588

Please sign in to comment.