forked from module-federation/core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
nxrelease.config.js
65 lines (64 loc) · 2.33 KB
/
nxrelease.config.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
58
59
60
61
62
63
64
65
/*
This project uses the nx-semantic-release plugin to automate the release process with semantic-release and nx.
The original plugin has some issues with ESM packages, so this we opted to use a forked version of the plugin.
- https://github.com/TheUnderScorer/nx-semantic-release (original version)
- https://github.com/goestav/nx-semantic-release (forked version with ESM support)
*/
// Here you can find the available options for the nx-semantic-release plugin.
// options https://github.com/goestav/nx-semantic-release#available-options
// options.branches https://github.com/semantic-release/semantic-release/blob/master/docs/usage/configuration.md#branches
// options.parserOpts https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-commits-parser#parseroptions
// options.releaseRules https://github.com/semantic-release/commit-analyzer#releaserules
module.exports = {
changelog: true,
git: true,
npm: true,
github: true,
repositoryUrl: 'https://github.com/module-federation/universe',
outputPath: 'dist/packages/${PROJECT_NAME}',
tagFormat: '${PROJECT_NAME}-${VERSION}',
commitMessage:
'chore(release): Release ${PROJECT_NAME} v${nextRelease.version} [skip ci]',
branches: [
{
name: 'main',
channel: 'latest',
},
{
name: 'next',
channel: 'next',
prerelease: 'rc',
},
{
name: 'canary',
channel: 'canary',
prerelease: 'canary',
},
],
parserOpts: {
mergePattern: /^Merged in (.*) \(pull request #(\d+)\)$/,
mergeCorrespondence: ['branch', 'id'],
},
releaseRules: [
{ breaking: true, release: 'major' },
{ type: 'docs', release: 'patch' },
{ type: 'refactor', release: 'patch' },
{ type: 'style', release: 'patch' },
{ type: 'perf', release: 'patch' },
{ type: 'build', release: 'patch' },
],
preset: 'conventionalcommits',
presetConfig: {
types: [
{ type: 'feat', section: 'Features' },
{ type: 'fix', section: 'Bug Fixes' },
{ type: 'chore', hidden: true },
{ type: 'docs', section: 'Documentation' },
{ type: 'style', hidden: true },
{ type: 'refactor', section: 'Refactors' },
{ type: 'build', section: 'Build config' },
{ type: 'perf', hidden: true },
{ type: 'test', hidden: true },
],
},
};