-
Notifications
You must be signed in to change notification settings - Fork 252
37 lines (35 loc) · 1.08 KB
/
Copy pathgithub-release.yml
File metadata and controls
37 lines (35 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: GitHub Release
on:
push:
tags:
- v*
jobs:
Publish:
permissions:
id-token: write
contents: write
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/v')
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Set up Ruby
uses: ruby/setup-ruby@984c0c890880bbf811283d6f09c4607c62d210a4
with:
bundler-cache: true
- name: Calculate release name
run: |
GITHUB_REF=${{ github.ref }}
RELEASE_NAME=${GITHUB_REF#"refs/tags/"}
echo "RELEASE_NAME=${RELEASE_NAME}" >> $GITHUB_ENV
- name: Publish release
uses: actions/create-release@0cb9c9b65d5d1901c1f53e5e66eaf4afd303e70e # v1.1.4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ env.RELEASE_NAME }}
draft: false
prerelease: false
- uses: rubygems/release-gem@7f9650160c1a4e7989fdc9855807bdbd421d8b6b # v1.4.1