-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.releaserc.js
57 lines (52 loc) · 1.34 KB
/
.releaserc.js
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
const commitAnalyzer = {
preset: 'conventionalcommits',
releaseRules: [
{ type: 'docs', scope: 'README', release: 'patch' },
{ type: 'ci', scope: 'patch', release: 'patch' },
{ type: 'ci', scope: 'major', release: 'major' },
{ type: 'ci', scope: 'minor', release: 'minor' },
],
}
const releaseNotes = {
preset: 'conventionalcommits',
}
const changelog = {
presetConfig: {
header:
'# 📝 Changelog\n\nAll notable changes to this project will be documented in this file.',
},
}
const npm = {
npmPublish: true,
}
const git = {
message:
"release: :bookmark: ${nextRelease.version} <%= new Date().toLocaleDateString('en-US', {year: 'numeric', month: 'short', day: 'numeric', hour: 'numeric', minute: 'numeric' }) %> [skip ci]\n\n${nextRelease.notes}",
assets: [
'dist/**',
'package.json',
'pnpm-lock.yaml',
'CHANGELOG.md',
'docs/**',
],
}
/**
* @type {import('semantic-release').GlobalConfig}
*/
export default {
branches: [
'main',
{
name: 'alpha',
prerelease: true,
},
],
plugins: [
['@semantic-release/commit-analyzer', commitAnalyzer],
['@semantic-release/release-notes-generator', releaseNotes],
['@semantic-release/changelog', changelog],
['semantic-release-pnpm', npm],
'@semantic-release/github',
['@semantic-release/git', git],
],
}