Skip to content

Commit bac3501

Browse files
committed
repo: add publish workflow
1 parent 84bf962 commit bac3501

2 files changed

Lines changed: 45 additions & 1 deletion

File tree

.github/workflows/publish.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
permissions:
9+
contents: write
10+
packages: write
11+
12+
jobs:
13+
github:
14+
name: GitHub
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v2
19+
- name: Install
20+
uses: ruby/setup-ruby@v1
21+
with:
22+
ruby-version: ruby-3
23+
bundler-cache: true
24+
- name: Publish to GitHub
25+
env:
26+
GEM_HOST_API_KEY: "Bearer ${{secrets.GITHUB_TOKEN}}"
27+
RUBYGEMS_HOST: https://rubygems.pkg.github.com/${{github.repository_owner}}
28+
run: bin/release
29+
rubygems:
30+
name: RubyGems
31+
runs-on: ubuntu-latest
32+
steps:
33+
- name: Checkout
34+
uses: actions/checkout@v2
35+
- name: Install
36+
uses: ruby/setup-ruby@v1
37+
with:
38+
ruby-version: ruby-3
39+
bundler-cache: true
40+
- name: Publish to RubyGems
41+
env:
42+
GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_TOKEN}}"
43+
run: bin/release

handlebars-engine.gemspec

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Gem::Specification.new do |spec|
66
spec.name = "handlebars-engine"
77
spec.version = Handlebars::Engine::VERSION
88
spec.authors = ["Zach Gianos"]
9-
spec.email = ["zach.gianos@gmail.com"]
9+
spec.email = ["zach.gianos+git@gmail.com"]
1010

1111
spec.summary = "A simple interface to Handlebars.js for Ruby."
1212
spec.description = <<-DESCRIPTION
@@ -18,6 +18,7 @@ Gem::Specification.new do |spec|
1818
spec.required_ruby_version = ">= 2.6.0"
1919

2020
spec.metadata["changelog_uri"] = "#{spec.homepage}/CHANGELOG.md"
21+
spec.metadata["github_repo"] = spec.homepage
2122
spec.metadata["homepage_uri"] = spec.homepage
2223
spec.metadata["rubygems_mfa_required"] = "true"
2324
spec.metadata["source_code_uri"] = spec.homepage

0 commit comments

Comments
 (0)