File tree Expand file tree Collapse file tree 1 file changed +51
-0
lines changed
Expand file tree Collapse file tree 1 file changed +51
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Publish gem to rubygems.org
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*'
7+
8+ permissions :
9+ contents : read
10+
11+ jobs :
12+ push :
13+ if : github.repository == 'ruby/racc'
14+ runs-on : ubuntu-latest
15+
16+ environment :
17+ name : rubygems.org
18+ url : https://rubygems.org/gems/racc
19+
20+ permissions :
21+ contents : write
22+ id-token : write
23+
24+ strategy :
25+ matrix :
26+ ruby : ["ruby", "jruby"]
27+
28+ steps :
29+ - name : Harden Runner
30+ uses : step-security/harden-runner@0634a2670c59f64b4a01f0f96f84700a4088b9f0 # v2.12.0
31+ with :
32+ egress-policy : audit
33+
34+ - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
35+
36+ - name : Set up Ruby
37+ uses : ruby/setup-ruby@13e7a03dc3ac6c3798f4570bfead2aed4d96abfb # v1.244.0
38+ with :
39+ bundler-cache : true
40+ ruby-version : ${{ matrix.ruby }}
41+
42+ - name : Publish to RubyGems
43+ uses : rubygems/release-gem@a25424ba2ba8b387abc8ef40807c2c85b96cbe32 # v1.1.1
44+
45+ - name : Create GitHub release
46+ run : |
47+ tag_name="$(git describe --tags --abbrev=0)"
48+ gh release create "${tag_name}" --verify-tag --generate-notes
49+ env :
50+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
51+ if : matrix.ruby == 'ruby'
You can’t perform that action at this time.
0 commit comments