@jcoreio/toolchain-semantic-release 5.3.0 → 5.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/release.config.cjs +107 -104
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jcoreio/toolchain-semantic-release",
|
|
3
|
-
"version": "5.3.
|
|
3
|
+
"version": "5.3.1",
|
|
4
4
|
"description": "toolchain for running semantic-release",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"dedent-js": "^1.0.1",
|
|
18
18
|
"resolve-bin": "^1.0.0",
|
|
19
|
-
"@jcoreio/toolchain": "5.3.
|
|
19
|
+
"@jcoreio/toolchain": "5.3.1"
|
|
20
20
|
},
|
|
21
21
|
"toolchainManaged": {
|
|
22
22
|
"optionalDevDependencies": {
|
package/release.config.cjs
CHANGED
|
@@ -18,8 +18,9 @@ try {
|
|
|
18
18
|
hasMain = false
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
const otherPackages =
|
|
22
|
-
|
|
21
|
+
const otherPackages =
|
|
22
|
+
monorepoSubpackageJsonFiles ?
|
|
23
|
+
monorepoSubpackageJsonFiles.map((f) => require(f).name)
|
|
23
24
|
: []
|
|
24
25
|
|
|
25
26
|
const base = {
|
|
@@ -34,110 +35,112 @@ const base = {
|
|
|
34
35
|
}
|
|
35
36
|
|
|
36
37
|
module.exports =
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
38
|
+
(
|
|
39
|
+
monorepoSubpackageJsonFiles &&
|
|
40
|
+
monorepoPackageJson &&
|
|
41
|
+
monorepoPackageJson.name !== '@jcoreio/toolchains'
|
|
42
|
+
) ?
|
|
43
|
+
{
|
|
44
|
+
...base,
|
|
45
|
+
// use separate git tags for each subpackage
|
|
46
|
+
tagFormat: `${pkg}-v\${version}`,
|
|
47
|
+
plugins: [
|
|
48
|
+
[
|
|
49
|
+
require.resolve('@semantic-release/commit-analyzer'),
|
|
50
|
+
{
|
|
51
|
+
preset: 'conventionalcommits',
|
|
52
|
+
releaseRules: [
|
|
53
|
+
// don't let commits scoped to other packages like fix(otherPackageName): ... trigger a release in this package
|
|
54
|
+
...otherPackages.flatMap((scope) => ({
|
|
55
|
+
scope,
|
|
56
|
+
release: false,
|
|
57
|
+
})),
|
|
58
|
+
...[
|
|
59
|
+
// make commits scoped to this package like fix(packageName): ... trigger a release in this package
|
|
60
|
+
pkg,
|
|
61
|
+
// make unscoped commits like fix: ... trigger a release in all packages
|
|
62
|
+
undefined,
|
|
63
|
+
].flatMap((scope) => [
|
|
64
|
+
{ breaking: true, scope, release: 'major' },
|
|
65
|
+
{ revert: true, scope, release: 'patch' },
|
|
66
|
+
{ type: 'feat', scope, release: 'minor' },
|
|
67
|
+
{ type: 'fix', scope, release: 'patch' },
|
|
68
|
+
{ type: 'perf', scope, release: 'patch' },
|
|
69
|
+
]),
|
|
70
|
+
// don't let any other types of commits trigger a release
|
|
71
|
+
{ scope: undefined, release: false },
|
|
72
|
+
],
|
|
73
|
+
},
|
|
74
|
+
],
|
|
75
|
+
[
|
|
76
|
+
require.resolve('@semantic-release/release-notes-generator'),
|
|
77
|
+
{
|
|
78
|
+
preset: 'conventionalcommits',
|
|
79
|
+
presetConfig: {
|
|
80
|
+
types: [
|
|
81
|
+
{ type: 'build', section: 'Build System', hidden: true },
|
|
82
|
+
{ type: 'chore', section: 'Build System', hidden: true },
|
|
83
|
+
{
|
|
84
|
+
type: 'ci',
|
|
85
|
+
section: 'Continuous Integration',
|
|
86
|
+
hidden: true,
|
|
87
|
+
},
|
|
88
|
+
{ type: 'style', section: 'Styles', hidden: true },
|
|
89
|
+
{ type: 'test', section: 'Tests', hidden: true },
|
|
55
90
|
...[
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
{
|
|
64
|
-
|
|
65
|
-
|
|
91
|
+
{ type: 'docs', section: 'Documentation' },
|
|
92
|
+
{ type: 'feat', section: 'Features' },
|
|
93
|
+
{ type: 'fix', section: 'Bug Fixes' },
|
|
94
|
+
{ type: 'perf', section: 'Performance Improvements' },
|
|
95
|
+
{ type: 'refactor', section: 'Code Refactoring' },
|
|
96
|
+
].flatMap((cfg) => [
|
|
97
|
+
// include commits scoped to this package like fix(packageName): ... in the release notes for this package
|
|
98
|
+
{ ...cfg, scope: pkg, hidden: false },
|
|
99
|
+
// exclude commits scoped to other packages like fix(otherPackageName): ... from the release notes for this package
|
|
100
|
+
...otherPackages.map((otherPkg) => ({
|
|
101
|
+
...cfg,
|
|
102
|
+
scope: otherPkg,
|
|
103
|
+
hidden: true,
|
|
104
|
+
})),
|
|
105
|
+
// include unscoped commits like fix: ... in the release notes for all packages
|
|
106
|
+
{ ...cfg, hidden: false },
|
|
66
107
|
]),
|
|
67
|
-
// don't let any other types of commits trigger a release
|
|
68
|
-
{ scope: undefined, release: false },
|
|
69
108
|
],
|
|
70
109
|
},
|
|
71
|
-
|
|
72
|
-
[
|
|
73
|
-
require.resolve('@semantic-release/release-notes-generator'),
|
|
74
|
-
{
|
|
75
|
-
preset: 'conventionalcommits',
|
|
76
|
-
presetConfig: {
|
|
77
|
-
types: [
|
|
78
|
-
{ type: 'build', section: 'Build System', hidden: true },
|
|
79
|
-
{ type: 'chore', section: 'Build System', hidden: true },
|
|
80
|
-
{
|
|
81
|
-
type: 'ci',
|
|
82
|
-
section: 'Continuous Integration',
|
|
83
|
-
hidden: true,
|
|
84
|
-
},
|
|
85
|
-
{ type: 'style', section: 'Styles', hidden: true },
|
|
86
|
-
{ type: 'test', section: 'Tests', hidden: true },
|
|
87
|
-
...[
|
|
88
|
-
{ type: 'docs', section: 'Documentation' },
|
|
89
|
-
{ type: 'feat', section: 'Features' },
|
|
90
|
-
{ type: 'fix', section: 'Bug Fixes' },
|
|
91
|
-
{ type: 'perf', section: 'Performance Improvements' },
|
|
92
|
-
{ type: 'refactor', section: 'Code Refactoring' },
|
|
93
|
-
].flatMap((cfg) => [
|
|
94
|
-
// include commits scoped to this package like fix(packageName): ... in the release notes for this package
|
|
95
|
-
{ ...cfg, scope: pkg, hidden: false },
|
|
96
|
-
// exclude commits scoped to other packages like fix(otherPackageName): ... from the release notes for this package
|
|
97
|
-
...otherPackages.map((otherPkg) => ({
|
|
98
|
-
...cfg,
|
|
99
|
-
scope: otherPkg,
|
|
100
|
-
hidden: true,
|
|
101
|
-
})),
|
|
102
|
-
// include unscoped commits like fix: ... in the release notes for all packages
|
|
103
|
-
{ ...cfg, hidden: false },
|
|
104
|
-
]),
|
|
105
|
-
],
|
|
106
|
-
},
|
|
107
|
-
},
|
|
108
|
-
],
|
|
109
|
-
...(_private
|
|
110
|
-
? []
|
|
111
|
-
: [
|
|
112
|
-
[
|
|
113
|
-
// this fork of @semantic-release/npm includes a patch that is necessary to fix an issue with monorepos
|
|
114
|
-
// https://github.com/semantic-release/npm/pull/531
|
|
115
|
-
require.resolve('@jcoreio/semantic-release-npm'),
|
|
116
|
-
{
|
|
117
|
-
pkgRoot: path.join(projectDir, 'dist'),
|
|
118
|
-
},
|
|
119
|
-
],
|
|
120
|
-
]),
|
|
121
|
-
require.resolve('@semantic-release/github'),
|
|
122
|
-
...getPluginsArraySync('semanticReleasePlugins'),
|
|
110
|
+
},
|
|
123
111
|
],
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
112
|
+
...(_private ?
|
|
113
|
+
[]
|
|
114
|
+
: [
|
|
115
|
+
[
|
|
116
|
+
// this fork of @semantic-release/npm includes a patch that is necessary to fix an issue with monorepos
|
|
117
|
+
// https://github.com/semantic-release/npm/pull/531
|
|
118
|
+
require.resolve('@jcoreio/semantic-release-npm'),
|
|
119
|
+
{
|
|
120
|
+
pkgRoot: path.join(projectDir, 'dist'),
|
|
121
|
+
},
|
|
122
|
+
],
|
|
123
|
+
]),
|
|
124
|
+
require.resolve('@semantic-release/github'),
|
|
125
|
+
...getPluginsArraySync('semanticReleasePlugins'),
|
|
126
|
+
],
|
|
127
|
+
}
|
|
128
|
+
: {
|
|
129
|
+
...base,
|
|
130
|
+
plugins: [
|
|
131
|
+
require.resolve('@semantic-release/commit-analyzer'),
|
|
132
|
+
require.resolve('@semantic-release/release-notes-generator'),
|
|
133
|
+
...(_private ?
|
|
134
|
+
[]
|
|
135
|
+
: [
|
|
136
|
+
[
|
|
137
|
+
require.resolve('@jcoreio/semantic-release-npm'),
|
|
138
|
+
{
|
|
139
|
+
pkgRoot: path.join(projectDir, 'dist'),
|
|
140
|
+
},
|
|
141
|
+
],
|
|
142
|
+
]),
|
|
143
|
+
require.resolve('@semantic-release/github'),
|
|
144
|
+
...getPluginsArraySync('semanticReleasePlugins'),
|
|
145
|
+
],
|
|
146
|
+
}
|