-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathrelease.config.js
44 lines (40 loc) · 1001 Bytes
/
release.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
const { readdirSync } = require('fs');
const { join } = require('path');
const libDist = join(__dirname, 'dist/libs');
const packagesRoots = readdirSync(libDist).map(dir => join(libDist, dir));
packagesRoots.push(join(__dirname, 'libs/cli'));
const npmPlugins = packagesRoots.map(pkgRoot => [
'@semantic-release/npm',
{
pkgRoot,
},
]);
module.exports = {
branches: [
'+([0-9])?(.{+([0-9]),x}).x',
'main',
'next',
'next-major',
{ name: 'rc', prerelease: true },
{ name: 'beta', prerelease: true },
{ name: 'alpha', prerelease: true },
],
plugins: [
'@semantic-release/commit-analyzer',
'@semantic-release/release-notes-generator',
'@semantic-release/changelog',
...npmPlugins,
[
'@semantic-release/exec',
{
prepareCmd: 'node ./tools/sync-versions.js',
},
],
[
'@semantic-release/git',
{
assets: ['CHANGELOG.md', 'libs/*/package.json', 'libs/*/README.md'],
},
],
],
};