-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (59 loc) · 1.64 KB
/
Copy pathpublish.yml
File metadata and controls
61 lines (59 loc) · 1.64 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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Publish Package
permissions:
id-token: write
on:
push:
tags:
- '*'
jobs:
npm:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v6
with:
node-version-file: '.tool-versions'
registry-url: 'https://registry.npmjs.org'
- run: npm version from-git --git-tag-version=false
- run: npm ci
- run: npm run build
- run: npm publish --tag latest
rubygems:
runs-on: ubuntu-latest
defaults:
run:
working-directory: gem
steps:
# Set up
- uses: actions/checkout@v5
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.4.7'
- uses: oven-sh/setup-bun@v2
with:
bun-version-file: ".tool-versions"
- uses: actions/setup-node@v6
with:
node-version-file: '.tool-versions'
registry-url: 'https://registry.npmjs.org'
- run: npm ci
working-directory: .
- run: npm run build
working-directory: .
- run: npm ci
working-directory: entrypoint
- name: Install gems
run: bundle install
- name: Set version
run: sed -i "s/VERSION = '0.0.0'/VERSION = '${GITHUB_REF_NAME#v}'/" lib/triangulum/version.rb && bundle
- name: Prepare build
run: bundle exec rake prepare_build
- name: Package gems
run: bundle exec rake package
# Release
- uses: rubygems/configure-rubygems-credentials@v1.0.0
- name: Publish gem
run: bundle exec rake push:all
- name: Wait for release
run: gem exec rubygems-await pkg/*.gem