Skip to content

Commit 862bfc3

Browse files
committed
chore(release): add semantic-release
1 parent 2c8e2c0 commit 862bfc3

File tree

2 files changed

+31
-0
lines changed

2 files changed

+31
-0
lines changed

.github/workflows/nodejs.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,11 @@ jobs:
3232
CODECOVS_TOKEN: ${{ secrets.CODECOVS_TOKEN }}
3333
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
3434
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
35+
- name: release
36+
only:
37+
- master
38+
run: yarn semantic-release
39+
env:
40+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
42+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

.releaserc.js

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
module.exports = {
2+
branches: [
3+
'master',
4+
'next',
5+
'next-major',
6+
{
7+
name: 'beta',
8+
prerelease: true
9+
},
10+
{
11+
name: 'alpha',
12+
prerelease: true
13+
}
14+
],
15+
plugins: [
16+
'@semantic-release/commit-analyzer',
17+
'@semantic-release/release-notes-generator',
18+
'@semantic-release/npm',
19+
'@semantic-release/github',
20+
['@semantic-release/changelog', { changelogFile: 'CHANGELOG.md', changelogTitle: '# Changelog' }],
21+
['@semantic-release/git', { assets: ['CHANGELOG.md'] }]
22+
]
23+
};

0 commit comments

Comments
 (0)