This repository has been archived by the owner on Dec 31, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.releaserc.js
63 lines (59 loc) · 1.69 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
58
59
60
61
62
63
const path = require('path');
const process = require('process');
const packageName = process.cwd().split(path.sep).pop();
let config;
if (packageName === 'ts-slonik-live-server-plugin') {
console.log('loading config for', packageName);
config = {
extends: 'semantic-release-monorepo',
branches: ['main', { name: 'preview', prerelease: true }],
plugins: [
'@semantic-release/commit-analyzer',
'@semantic-release/release-notes-generator',
'@semantic-release/changelog',
'@semantic-release/npm',
'@semantic-release/github',
[
'@semantic-release/git',
{
assets: ['package.json', 'CHANGELOG.md'],
message: 'chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}',
},
],
],
};
} else if (packageName === 'vscode-slonik-live-server') {
console.log('loading config for', packageName);
config = {
extends: 'semantic-release-monorepo',
branches: ['main'],
plugins: [
'@semantic-release/commit-analyzer',
'@semantic-release/release-notes-generator',
'@semantic-release/changelog',
[
'semantic-release-vsce',
{
packageVsix: true,
},
],
[
'@semantic-release/github',
{
assets: [{ path: './*.vsix' }],
},
],
[
'@semantic-release/git',
{
assets: ['package.json', 'CHANGELOG.md'],
message: 'chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}',
},
],
],
};
} else {
console.log(`\npackage ${packageName} is not listed for semantic-release, exiting\n\n`);
process.exit(1);
}
module.exports = config;