Skip to content

Commit 1ed7337

Browse files
committed
ci: simple-release
1 parent 383d037 commit 1ed7337

File tree

12 files changed

+228
-4329
lines changed

12 files changed

+228
-4329
lines changed

.github/workflows/release.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: Release
2+
on:
3+
issue_comment:
4+
types: [created, deleted]
5+
push:
6+
branches:
7+
- main
8+
jobs:
9+
check:
10+
runs-on: ubuntu-latest
11+
name: Context check
12+
outputs:
13+
continue: ${{ steps.check.outputs.continue }}
14+
workflow: ${{ steps.check.outputs.workflow }}
15+
steps:
16+
- name: Checkout the repository
17+
uses: actions/checkout@v4
18+
- name: Context check
19+
id: check
20+
uses: trigensoftware/simple-release-action@latest
21+
with:
22+
workflow: check
23+
github-token: ${{ secrets.GITHUB_TOKEN }}
24+
pull-request:
25+
runs-on: ubuntu-latest
26+
name: Pull request
27+
needs: check
28+
if: needs.check.outputs.workflow == 'pull-request'
29+
steps:
30+
- name: Checkout the repository
31+
uses: actions/checkout@v4
32+
- name: Create or update pull request
33+
uses: trigensoftware/simple-release-action@latest
34+
with:
35+
workflow: pull-request
36+
github-token: ${{ secrets.GITHUB_TOKEN }}
37+
release:
38+
runs-on: ubuntu-latest
39+
name: Release
40+
needs: check
41+
if: needs.check.outputs.workflow == 'release'
42+
steps:
43+
- name: Checkout the repository
44+
uses: actions/checkout@v4
45+
- name: Install pnpm
46+
uses: pnpm/action-setup@v4
47+
with:
48+
version: 10
49+
- name: Install Node.js
50+
uses: actions/setup-node@v4
51+
with:
52+
node-version: 22
53+
cache: 'pnpm'
54+
registry-url: 'https://registry.npmjs.org'
55+
- name: Install dependencies
56+
run: pnpm install
57+
- name: Release
58+
uses: trigensoftware/simple-release-action@latest
59+
with:
60+
workflow: release
61+
github-token: ${{ secrets.GITHUB_TOKEN }}
62+
npm-token: ${{ secrets.NPM_TOKEN }}

.simple-release.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"project": ["@simple-release/pnpm#PnpmWorkspacesProject", {
3+
"mode": "fixed"
4+
}],
5+
"releaser": {
6+
"verbose": true
7+
},
8+
"publish": {
9+
"access": "public"
10+
}
11+
}

0 commit comments

Comments
 (0)