Skip to content

Commit 2e453ed

Browse files
committed
Add workflow to release gem via GitHub Actions
1 parent eed99fd commit 2e453ed

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

.github/workflows/release.yml

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Release Gem
2+
3+
on:
4+
push:
5+
branches: ["master"]
6+
paths: ["lib/**/version.rb"]
7+
8+
jobs:
9+
release:
10+
if: "github.repository_owner == 'jekyll'"
11+
name: "Release Gem (Ruby ${{ matrix.ruby_version }})"
12+
runs-on: "ubuntu-latest"
13+
strategy:
14+
fail-fast: true
15+
matrix:
16+
ruby_version: ["2.7"]
17+
steps:
18+
- name: Checkout Repository
19+
uses: actions/checkout@v4
20+
- name: "Set up Ruby ${{ matrix.ruby_version }}"
21+
uses: ruby/setup-ruby@v1
22+
with:
23+
ruby-version: ${{ matrix.ruby_version }}
24+
bundler-cache: true
25+
- name: Build and Publish Gem
26+
uses: ashmaroli/release-gem@dist
27+
with:
28+
gemspec_name: "jekyll-archives"
29+
env:
30+
GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_GEM_PUSH_API_KEY }}

0 commit comments

Comments
 (0)