Skip to content

Commit af69a35

Browse files
committed
chore: split release workflow into two jobs
1 parent d54abb8 commit af69a35

File tree

1 file changed

+44
-12
lines changed

1 file changed

+44
-12
lines changed

.github/workflows/release.yml

Lines changed: 44 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,8 @@ on:
55
- cron: '0 23 * * *'
66
workflow_dispatch:
77

8-
permissions:
9-
contents: read
10-
id-token: write
11-
128
jobs:
13-
release:
9+
build:
1410
runs-on: macos-latest
1511
steps:
1612
- name: Checkout
@@ -19,11 +15,6 @@ jobs:
1915
fetch-depth: 0
2016
token: ${{ secrets.GH_ADMIN_TOKEN }}
2117

22-
- name: Set up Git
23-
run: |
24-
git config --local user.name "Artem Zakharchenko"
25-
git config --local user.email "kettanaito@gmail.com"
26-
2718
- name: Set up pnpm
2819
uses: pnpm/action-setup@v4
2920
with:
@@ -33,8 +24,6 @@ jobs:
3324
uses: actions/setup-node@v4
3425
with:
3526
node-version: 22
36-
always-auth: true
37-
registry-url: https://registry.npmjs.org
3827

3928
- name: Install dependencies
4029
run: pnpm install
@@ -48,6 +37,49 @@ jobs:
4837
- name: Test
4938
run: pnpm test
5039

40+
- name: Upload build artifacts
41+
uses: actions/upload-artifact@v4
42+
with:
43+
name: build-artifacts
44+
path: ./lib
45+
46+
release:
47+
needs: [build]
48+
runs-on: macos-latest
49+
permissions:
50+
contents: read
51+
id-token: write
52+
steps:
53+
- name: Checkout
54+
uses: actions/checkout@v4
55+
with:
56+
fetch-depth: 0
57+
token: ${{ secrets.GH_ADMIN_TOKEN }}
58+
59+
- name: Set up Git
60+
run: |
61+
git config --local user.name "Artem Zakharchenko"
62+
git config --local user.email "kettanaito@gmail.com"
63+
64+
- name: Set up pnpm
65+
uses: pnpm/action-setup@v4
66+
with:
67+
version: 9.15.0
68+
69+
- name: Set up Node.js
70+
uses: actions/setup-node@v4
71+
with:
72+
node-version: 24
73+
74+
- name: Install dependencies
75+
run: pnpm install
76+
77+
- name: Download build artifacts
78+
uses: actions/download-artifact@v4
79+
with:
80+
name: build-artifacts
81+
path: ./lib
82+
5183
- name: Release
5284
run: pnpm release
5385
env:

0 commit comments

Comments
 (0)