Skip to content

Commit e92633e

Browse files
committed
feat: Update semantic configuration and add changelog workflow
1 parent 74c74ac commit e92633e

File tree

4 files changed

+76
-8
lines changed

4 files changed

+76
-8
lines changed

.github/semantic.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
titleAndCommits: true
22
allowMergeCommits: false
33
scopes:
4-
- deps
5-
- deps-dev
4+
- core
5+
- api
6+
- common
7+
- chore
68
types:
79
- feat
810
- fix

.github/workflows/changelog.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Changelog
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
changelog:
10+
name: Changelog
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: "Checkout repository"
14+
uses: actions/checkout@v4
15+
16+
- name: "Setup pnpm"
17+
uses: pnpm/action-setup@v4
18+
with:
19+
version: latest
20+
run_install: false
21+
22+
- name: "Set up Node.js"
23+
uses: actions/setup-node@v4
24+
with:
25+
node-version: 20
26+
registry-url: "https://registry.npmjs.org"
27+
cache: "pnpm"
28+
29+
- name: "Install dependencies"
30+
run: pnpm install
31+
32+
- name: "Generate changelog"
33+
run: pnpm changelog
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Release to npm
2+
3+
on:
4+
workflow_dispatch:
5+
release:
6+
types: [created] # Runs only when a new GitHub Release is created
7+
8+
jobs:
9+
build:
10+
name: Build
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout repository
14+
uses: actions/checkout@v4
15+
16+
- name: Setup pnpm
17+
uses: pnpm/action-setup@v4
18+
with:
19+
version: latest
20+
run_install: false
21+
22+
- name: Set up Node.js
23+
uses: actions/setup-node@v4
24+
with:
25+
node-version: 20
26+
registry-url: "https://registry.npmjs.org"
27+
cache: "pnpm"
28+
29+
- name: Install dependencies
30+
run: pnpm install
31+
32+
- name: Run lint
33+
run: pnpm lint
34+
35+
- name: Run tests
36+
run: pnpm test
37+
38+
- name: Build package
39+
run: pnpm build
Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,3 @@ jobs:
4545
run: pnpm publish --access public
4646
env:
4747
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
48-
49-
- name: Create GitHub Release
50-
uses: softprops/action-gh-release@v2
51-
with:
52-
tag_name: ${{ github.ref_name }}
53-
generate_release_notes: true

0 commit comments

Comments
 (0)