@vc-shell/release-config 1.1.97 → 1.1.98-rc.0
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/LICENSE +12 -0
- package/README.md +280 -32
- package/dist/release-config.js +246 -126
- package/dist/release.d.ts +18 -6
- package/dist/release.d.ts.map +1 -1
- package/package.json +7 -4
- package/CHANGELOG.md +0 -1364
package/dist/release-config.js
CHANGED
|
@@ -1,98 +1,105 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { readFileSync as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import { argv as
|
|
8
|
-
import { sync as
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
function w(
|
|
12
|
-
const
|
|
13
|
-
return { pkg: JSON.parse(
|
|
1
|
+
import v from "prompts";
|
|
2
|
+
import { parse as P, valid as V } from "semver";
|
|
3
|
+
import { readFileSync as b, writeFileSync as k, existsSync as S } from "node:fs";
|
|
4
|
+
import C from "node:path";
|
|
5
|
+
import n from "chalk";
|
|
6
|
+
import T from "mri";
|
|
7
|
+
import { argv as j } from "node:process";
|
|
8
|
+
import { sync as y } from "cross-spawn";
|
|
9
|
+
const r = T(j.slice(2)), R = !!r.dry;
|
|
10
|
+
R && (console.log(n.inverse(n.yellow(" DRY RUN "))), console.log());
|
|
11
|
+
function w(a) {
|
|
12
|
+
const g = C.resolve(a), f = C.resolve(g, "package.json");
|
|
13
|
+
return { pkg: JSON.parse(b(f, "utf-8")), pkgDir: g, pkgPath: f };
|
|
14
14
|
}
|
|
15
|
-
async function
|
|
16
|
-
if (
|
|
17
|
-
console.log(
|
|
15
|
+
async function G(a, g) {
|
|
16
|
+
if (R) {
|
|
17
|
+
console.log(n.blue(`[dryrun] Writing package.json to ${a}`));
|
|
18
18
|
return;
|
|
19
19
|
}
|
|
20
|
-
|
|
20
|
+
k(a, JSON.stringify(g, null, 2) + `
|
|
21
21
|
`, "utf-8");
|
|
22
22
|
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const f = b ? A : P;
|
|
30
|
-
function d(t) {
|
|
31
|
-
return console.log(s.cyan(t));
|
|
32
|
-
}
|
|
33
|
-
function E(t) {
|
|
34
|
-
function n(r, o) {
|
|
35
|
-
if (r === "prerelease" && o === "alpha") {
|
|
36
|
-
if (t.includes("-alpha")) {
|
|
37
|
-
const [h, p] = t.split("-alpha."), $ = parseInt(p) + 1;
|
|
38
|
-
return `${h}-alpha.${$}`;
|
|
39
|
-
}
|
|
40
|
-
return `${y(t, "patch")}-alpha.0`;
|
|
41
|
-
}
|
|
42
|
-
return y(t, r);
|
|
43
|
-
}
|
|
44
|
-
return [
|
|
45
|
-
{
|
|
46
|
-
title: "next",
|
|
47
|
-
value: n("patch")
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
title: "alpha",
|
|
51
|
-
value: n("prerelease", "alpha")
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
title: "minor",
|
|
55
|
-
value: n("minor")
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
title: "major",
|
|
59
|
-
value: n("major")
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
value: "custom",
|
|
63
|
-
title: "custom"
|
|
64
|
-
}
|
|
65
|
-
].map((r) => (r.title = `${r.title} (${r.value})`, r));
|
|
66
|
-
}
|
|
67
|
-
const W = async ({
|
|
68
|
-
packages: t,
|
|
69
|
-
bumpVersion: n,
|
|
70
|
-
generateChangelog: l,
|
|
71
|
-
toTag: r
|
|
23
|
+
const M = async ({
|
|
24
|
+
packages: a,
|
|
25
|
+
bumpVersion: g,
|
|
26
|
+
generateChangelog: f,
|
|
27
|
+
toTag: t,
|
|
28
|
+
customHooks: u
|
|
72
29
|
}) => {
|
|
73
|
-
|
|
74
|
-
if (t.length === 0)
|
|
30
|
+
if (a.length === 0)
|
|
75
31
|
throw new Error("No packages to release");
|
|
76
|
-
const
|
|
77
|
-
|
|
78
|
-
|
|
32
|
+
const c = !!r.dry;
|
|
33
|
+
c && console.log(n.yellow(`
|
|
34
|
+
⚠️ DRY RUN MODE - No git operations will be performed
|
|
35
|
+
`));
|
|
36
|
+
const { releaseType: d } = await v({
|
|
37
|
+
type: "select",
|
|
38
|
+
name: "releaseType",
|
|
39
|
+
message: "Select release type",
|
|
40
|
+
choices: [
|
|
41
|
+
{ title: "Automatic (based on commits)", value: "auto" },
|
|
42
|
+
{ title: "Prerelease (alpha/beta/rc)", value: "prerelease" },
|
|
43
|
+
{ title: "Graduate prerelease to stable", value: "graduate" },
|
|
44
|
+
{ title: "Custom version", value: "custom" }
|
|
45
|
+
]
|
|
46
|
+
});
|
|
47
|
+
if (!d) {
|
|
48
|
+
console.log(n.yellow(`
|
|
49
|
+
Release cancelled
|
|
50
|
+
`));
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
const l = ["lerna", "version", "--conventional-commits"];
|
|
54
|
+
if (d === "prerelease") {
|
|
55
|
+
const { pkg: p } = w(a[0]), o = P(p.version), e = o && o.prerelease.length > 0, s = e ? o.prerelease[0] : null, { preid: i } = await v({
|
|
79
56
|
type: "select",
|
|
80
|
-
name: "
|
|
81
|
-
message: "Select
|
|
82
|
-
choices:
|
|
57
|
+
name: "preid",
|
|
58
|
+
message: "Select prerelease identifier",
|
|
59
|
+
choices: [
|
|
60
|
+
{
|
|
61
|
+
title: e && s === "alpha" ? "alpha (continue)" : "alpha",
|
|
62
|
+
value: "alpha"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
title: e && s === "beta" ? "beta (continue)" : "beta",
|
|
66
|
+
value: "beta"
|
|
67
|
+
},
|
|
68
|
+
{ title: e && s === "rc" ? "rc (continue)" : "rc", value: "rc" }
|
|
69
|
+
]
|
|
83
70
|
});
|
|
84
|
-
|
|
71
|
+
if (!i) {
|
|
72
|
+
console.log(n.yellow(`
|
|
73
|
+
Release cancelled
|
|
74
|
+
`));
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
e && s === i ? l.push("prerelease") : l.push("prerelease", "--preid", i), r.tag || (r.tag = i);
|
|
78
|
+
} else if (d === "graduate")
|
|
79
|
+
l.push("--conventional-graduate");
|
|
80
|
+
else if (d === "custom") {
|
|
81
|
+
const { pkg: p } = w(a[0]), { customVersion: o } = await v({
|
|
85
82
|
type: "text",
|
|
86
|
-
name: "
|
|
87
|
-
message: "
|
|
88
|
-
initial:
|
|
89
|
-
|
|
83
|
+
name: "customVersion",
|
|
84
|
+
message: "Enter custom version",
|
|
85
|
+
initial: p.version,
|
|
86
|
+
validate: (s) => V(s) ? !0 : "Invalid semver version"
|
|
87
|
+
});
|
|
88
|
+
if (!o) {
|
|
89
|
+
console.log(n.yellow(`
|
|
90
|
+
Release cancelled
|
|
91
|
+
`));
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
l.push(o);
|
|
95
|
+
const e = P(o);
|
|
96
|
+
if (e && e.prerelease.length > 0 && !r.tag) {
|
|
97
|
+
const s = e.prerelease[0];
|
|
98
|
+
typeof s == "string" && (r.tag = s);
|
|
99
|
+
}
|
|
90
100
|
}
|
|
91
|
-
if (!
|
|
92
|
-
|
|
93
|
-
const h = o.match(/-([a-zA-Z]+)(?:\.(\d+))?$/);
|
|
94
|
-
if (h && !e.tag && (e.tag = h[1]), !e.tag) {
|
|
95
|
-
const { npmTag: a } = await u({
|
|
101
|
+
if (!r.tag) {
|
|
102
|
+
const { npmTag: p } = await v({
|
|
96
103
|
type: "select",
|
|
97
104
|
name: "npmTag",
|
|
98
105
|
message: "Select npm distribution tag",
|
|
@@ -104,59 +111,172 @@ const W = async ({
|
|
|
104
111
|
{ title: "custom", value: "custom" }
|
|
105
112
|
]
|
|
106
113
|
});
|
|
107
|
-
if (
|
|
108
|
-
const
|
|
114
|
+
if (p === "custom") {
|
|
115
|
+
const o = await v({
|
|
109
116
|
type: "text",
|
|
110
117
|
name: "customTag",
|
|
111
118
|
message: "Input custom npm tag",
|
|
112
119
|
initial: "latest"
|
|
113
120
|
});
|
|
114
|
-
|
|
115
|
-
} else
|
|
116
|
-
}
|
|
117
|
-
if (e.tag && e.tag !== "latest") {
|
|
118
|
-
const a = R(o);
|
|
119
|
-
if (a && !o.includes(`-${e.tag}`)) {
|
|
120
|
-
let i, c = 0;
|
|
121
|
-
a.prerelease.length > 0 ? (a.prerelease.length > 1 && typeof a.prerelease[1] == "number" && (c = a.prerelease[1]), i = `${`${a.major}.${a.minor}.${a.patch}`}-${e.tag}`) : i = `${y(o, "minor")}-${e.tag}`;
|
|
122
|
-
const { usePreNum: m } = await u({
|
|
123
|
-
type: "confirm",
|
|
124
|
-
name: "usePreNum",
|
|
125
|
-
message: `Add prerelease number to version? (e.g. ${i}.${c})`,
|
|
126
|
-
initial: !0
|
|
127
|
-
});
|
|
128
|
-
m && (i = `${i}.${c}`);
|
|
129
|
-
}
|
|
121
|
+
r.tag = o.customTag;
|
|
122
|
+
} else p !== "latest" && (r.tag = p);
|
|
130
123
|
}
|
|
131
|
-
const
|
|
132
|
-
let $ = `release: ${p}`;
|
|
133
|
-
e.tag && e.tag !== "latest" && ($ += ` with npm tag ${e.tag}`);
|
|
134
|
-
const { yes: N } = await u({
|
|
124
|
+
const { yes: h } = await v({
|
|
135
125
|
type: "confirm",
|
|
136
126
|
name: "yes",
|
|
137
|
-
message: `
|
|
127
|
+
message: `Ready to release${r.tag && r.tag !== "latest" ? ` with npm tag ${n.blue(r.tag)}` : ""}. Continue?`
|
|
138
128
|
});
|
|
139
|
-
if (!
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
Updating ${s.green(i.name)} package version to ${s.green(o)}...`), await n(i.name, o);
|
|
144
|
-
const c = w(g), m = { ...c.pkg };
|
|
145
|
-
e.tag && e.tag !== "latest" ? (m.npmTag = e.tag, await T(c.pkgPath, m), console.log(`Set npmTag: ${s.blue(e.tag)} to ${s.green(i.name)}`)) : m.npmTag && (delete m.npmTag, await T(c.pkgPath, m), console.log(`Removed npmTag from ${s.green(i.name)} for latest release.`)), d(`
|
|
146
|
-
Generating ${s.green(i.name)} changelog...`), await l(i.name, o, g);
|
|
147
|
-
}
|
|
148
|
-
const { stdout: j } = await P("git", ["diff"], { stdio: "pipe" });
|
|
149
|
-
if (j)
|
|
150
|
-
d(`
|
|
151
|
-
Committing changes...`), await f("git", ["add", "-A"]), await f("git", ["commit", "-m", $, "--no-verify"]), await f("git", ["tag", p]);
|
|
152
|
-
else {
|
|
153
|
-
console.log("No changes to commit.");
|
|
129
|
+
if (!h) {
|
|
130
|
+
console.log(n.yellow(`
|
|
131
|
+
Release cancelled
|
|
132
|
+
`));
|
|
154
133
|
return;
|
|
155
134
|
}
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
135
|
+
c ? l.push("--no-git-tag-version", "--no-push") : l.push("--no-push"), console.log(n.cyan(`
|
|
136
|
+
Running: npx ${l.join(" ")}
|
|
137
|
+
`));
|
|
138
|
+
const m = y("npx", l, { stdio: "inherit" });
|
|
139
|
+
if (m.status !== 0 && (console.error(n.red(`
|
|
140
|
+
❌ Release process failed
|
|
141
|
+
`)), process.exit(m.status || 1)), await E(a), u) {
|
|
142
|
+
console.log(n.cyan(`
|
|
143
|
+
Running post-version hooks...
|
|
144
|
+
`));
|
|
145
|
+
const { pkg: p } = w(a[0] === "." ? a[1] : a[0]);
|
|
146
|
+
await u(p.version);
|
|
147
|
+
}
|
|
148
|
+
if (await O(a), await H(a), await $(a), !c && y("git", ["status", "--porcelain"], { stdio: "pipe" }).stdout?.toString().trim()) {
|
|
149
|
+
const e = y("git", ["describe", "--tags", "--abbrev=0"], { stdio: "pipe" }).stdout?.toString().trim() || "HEAD";
|
|
150
|
+
y("git", ["add", "-A"], { stdio: "inherit" }), y("git", ["commit", "--amend", "--no-edit", "--no-verify"], { stdio: "inherit" }), y("git", ["tag", "-f", e], { stdio: "inherit" }), console.log(n.cyan(`
|
|
151
|
+
Pushing changes to remote...
|
|
152
|
+
`)), y("git", ["push", "origin", "HEAD", "--force-with-lease"], { stdio: "inherit" }), y("git", ["push", "origin", e, "--force"], { stdio: "inherit" }), console.log(n.green(`
|
|
153
|
+
✅ Updated changelogs, package.json, and pushed to remote
|
|
154
|
+
`));
|
|
155
|
+
}
|
|
156
|
+
c ? (console.log(n.yellow(`
|
|
157
|
+
✅ Dry run completed successfully!
|
|
158
|
+
`)), console.log(n.cyan("Changes made:")), console.log(n.cyan(" - Updated package versions")), console.log(n.cyan(" - Generated/updated CHANGELOG.md files")), console.log(n.cyan(` - Updated npmTag fields in package.json
|
|
159
|
+
`)), console.log(n.yellow("No git operations performed. Review changes with:")), console.log(n.cyan(` git diff
|
|
160
|
+
`)), console.log(n.yellow("To revert all changes:")), console.log(n.cyan(` git checkout -- .
|
|
161
|
+
`))) : (console.log(n.green(`
|
|
162
|
+
✅ Release completed successfully!
|
|
163
|
+
`)), r.tag && r.tag !== "latest" && (console.log(n.cyan(`
|
|
164
|
+
ℹ️ Package files updated with npmTag: ${n.blue(r.tag)}`)), console.log(n.cyan(` GitHub Actions will automatically publish with this tag
|
|
165
|
+
`))));
|
|
159
166
|
};
|
|
167
|
+
async function O(a) {
|
|
168
|
+
console.log(n.cyan(`
|
|
169
|
+
Enhancing changelogs...
|
|
170
|
+
`));
|
|
171
|
+
for (const g of a) {
|
|
172
|
+
if (g === ".") continue;
|
|
173
|
+
const f = C.join(g, "CHANGELOG.md");
|
|
174
|
+
if (!S(f)) continue;
|
|
175
|
+
let t = b(f, "utf-8");
|
|
176
|
+
t = t.replace(/^# CHANGELOG\s*\n/gm, ""), t = t.replace(/^# Change Log\s*\n/gm, ""), t = t.replace(/^All notable changes to this (project|package) will be documented in this file\.\s*\n/gm, ""), t = t.replace(
|
|
177
|
+
/^See \[Conventional Commits\]\(https:\/\/conventionalcommits\.org\) for commit guidelines\.\s*\n/gm,
|
|
178
|
+
""
|
|
179
|
+
), t = t.replace(/\n{3,}/g, `
|
|
180
|
+
|
|
181
|
+
`), t = t.replace(
|
|
182
|
+
/^(##\s+\[[^\]]+\][^\n]*\n)\n(##\s+\[|$)/gm,
|
|
183
|
+
`$1
|
|
184
|
+
**Note:** Version bump only for package
|
|
185
|
+
|
|
186
|
+
$2`
|
|
187
|
+
), t = t.trim() + `
|
|
188
|
+
`, k(f, t, "utf-8");
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
async function E(a) {
|
|
192
|
+
const g = a.find((d) => d !== ".");
|
|
193
|
+
if (!g) return;
|
|
194
|
+
const { pkg: f } = w(g), t = f.version, u = "package.json", c = JSON.parse(b(u, "utf-8"));
|
|
195
|
+
c.version !== t && (c.version = t, k(u, JSON.stringify(c, null, 2) + `
|
|
196
|
+
`, "utf-8"), console.log(n.gray(` Updated root package.json version: ${t}`)));
|
|
197
|
+
}
|
|
198
|
+
async function H(a) {
|
|
199
|
+
console.log(n.cyan(`
|
|
200
|
+
Generating root CHANGELOG with package grouping...
|
|
201
|
+
`));
|
|
202
|
+
const g = "CHANGELOG.md", f = {
|
|
203
|
+
framework: "VC-Shell Framework (@vc-shell/framework)",
|
|
204
|
+
"cli/api-client": "API Client Generator (@vc-shell/api-client-generator)",
|
|
205
|
+
"cli/create-vc-app": "Create VC App (@vc-shell/create-vc-app)",
|
|
206
|
+
"configs/release-config": "Release Config (@vc-shell/release-config)",
|
|
207
|
+
"configs/vite-config": "Vite Config (@vc-shell/config-generator)",
|
|
208
|
+
"configs/ts-config": "TypeScript Config (@vc-shell/ts-config)"
|
|
209
|
+
}, t = {}, u = {};
|
|
210
|
+
for (const l of a) {
|
|
211
|
+
if (l === ".") continue;
|
|
212
|
+
const h = C.join(l, "CHANGELOG.md"), m = f[l] || l;
|
|
213
|
+
if (!S(h)) continue;
|
|
214
|
+
const o = b(h, "utf-8").split(`
|
|
215
|
+
`);
|
|
216
|
+
let e = null, s = [];
|
|
217
|
+
for (const i of o) {
|
|
218
|
+
const N = i.match(/^##\s+(?:\[)?([\d.a-z-]+)(?:\])?(?:\s+\([^)]+\))?/i);
|
|
219
|
+
if (N) {
|
|
220
|
+
if (e && s.length > 0) {
|
|
221
|
+
const A = s.join(`
|
|
222
|
+
`).trim();
|
|
223
|
+
t[e] || (t[e] = {}), t[e][m] = A;
|
|
224
|
+
}
|
|
225
|
+
e = N[1], s = [], u[e] || (u[e] = i.replace(/^##\s+/, ""));
|
|
226
|
+
} else e && i.trim() !== "" && !i.startsWith("# CHANGELOG") && !i.startsWith("# Change Log") && !i.startsWith("All notable changes") && !i.startsWith("See [Conventional Commits]") && s.push(i);
|
|
227
|
+
}
|
|
228
|
+
if (e && s.length > 0) {
|
|
229
|
+
const i = s.join(`
|
|
230
|
+
`).trim();
|
|
231
|
+
t[e] || (t[e] = {}), t[e][m] = i;
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
let c = "";
|
|
235
|
+
const d = Object.keys(t).sort((l, h) => {
|
|
236
|
+
const m = l.split(/[.-]/).map((o) => isNaN(parseInt(o)) ? o : parseInt(o)), p = h.split(/[.-]/).map((o) => isNaN(parseInt(o)) ? o : parseInt(o));
|
|
237
|
+
for (let o = 0; o < Math.max(m.length, p.length); o++) {
|
|
238
|
+
const e = m[o] ?? 0, s = p[o] ?? 0;
|
|
239
|
+
if (e !== s)
|
|
240
|
+
return typeof e == "number" && typeof s == "number" ? s - e : String(s).localeCompare(String(e));
|
|
241
|
+
}
|
|
242
|
+
return 0;
|
|
243
|
+
});
|
|
244
|
+
for (const l of d) {
|
|
245
|
+
const h = t[l], m = Object.values(h).some((e) => !e || !e.trim() ? !1 : e.replace(/\*\*Note:\*\*\s+Version bump only[^\n]*/gi, "").trim().length > 0), p = u[l] || l;
|
|
246
|
+
if (c += `## ${p}
|
|
247
|
+
|
|
248
|
+
`, !m) {
|
|
249
|
+
c += `**Note:** Version bump only for package
|
|
250
|
+
|
|
251
|
+
`;
|
|
252
|
+
continue;
|
|
253
|
+
}
|
|
254
|
+
let o = !1;
|
|
255
|
+
for (const e of a) {
|
|
256
|
+
if (e === ".") continue;
|
|
257
|
+
const s = f[e] || e, i = h[s];
|
|
258
|
+
i && i.trim() && i.replace(/\*\*Note:\*\*\s+Version bump only[^\n]*/gi, "").trim().length > 0 && (o = !0, c += `### ${s}
|
|
259
|
+
|
|
260
|
+
`, c += `${i}
|
|
261
|
+
|
|
262
|
+
`);
|
|
263
|
+
}
|
|
264
|
+
o || (c += `**Note:** Version bump only for package
|
|
265
|
+
|
|
266
|
+
`);
|
|
267
|
+
}
|
|
268
|
+
c = c.replace(/\n{3,}/g, `
|
|
269
|
+
|
|
270
|
+
`), k(g, c, "utf-8"), console.log(n.green(" ✓ Generated root CHANGELOG.md with package grouping"));
|
|
271
|
+
}
|
|
272
|
+
async function $(a) {
|
|
273
|
+
if (r.tag)
|
|
274
|
+
for (const g of a) {
|
|
275
|
+
if (g === ".") continue;
|
|
276
|
+
const { pkg: f, pkgPath: t } = w(g), u = { ...f };
|
|
277
|
+
r.tag !== "latest" ? (u.npmTag = r.tag, await G(t, u)) : u.npmTag && (delete u.npmTag, await G(t, u));
|
|
278
|
+
}
|
|
279
|
+
}
|
|
160
280
|
export {
|
|
161
|
-
|
|
281
|
+
M as release
|
|
162
282
|
};
|
package/dist/release.d.ts
CHANGED
|
@@ -1,16 +1,28 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Release function that
|
|
2
|
+
* Release function that uses Lerna for versioning and changelog generation
|
|
3
3
|
* @param packages - An array of package names to release.
|
|
4
|
-
* @param bumpVersion - A function that takes a package name and version
|
|
4
|
+
* @param bumpVersion - A function that takes a package name and version (deprecated, Lerna handles this).
|
|
5
5
|
* @param generateChangelog - A function that generates a changelog for a package with a given version.
|
|
6
6
|
* @param toTag - A function that takes a version and returns a tag name.
|
|
7
|
+
* @param customHooks - A function that takes a package name, version, and workspace name and returns a void or Promise<void>.
|
|
7
8
|
* @returns void
|
|
8
9
|
* @throws Error if there are no packages to release or if the target version is invalid.
|
|
9
10
|
*/
|
|
10
|
-
export declare const release: ({ packages, bumpVersion, generateChangelog, toTag, }: {
|
|
11
|
+
export declare const release: ({ packages, bumpVersion, generateChangelog, toTag, customHooks, }: {
|
|
11
12
|
packages: string[];
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @param pkgName
|
|
16
|
+
* @param version
|
|
17
|
+
* @param workspaceName
|
|
18
|
+
* @returns
|
|
19
|
+
*/
|
|
20
|
+
customHooks: (version: string) => void | Promise<void>;
|
|
21
|
+
/** @deprecated Lerna handles version bumping automatically */
|
|
22
|
+
bumpVersion?: (pkgName: string, version: string) => void | Promise<void>;
|
|
23
|
+
/** @deprecated Lerna generates changelogs automatically */
|
|
24
|
+
generateChangelog?: (pkgName: string, version: string, workspaceName?: string) => void | Promise<void>;
|
|
25
|
+
/** @deprecated Lerna handles version bumping automatically */
|
|
26
|
+
toTag?: (version: string) => string;
|
|
15
27
|
}) => Promise<void>;
|
|
16
28
|
//# sourceMappingURL=release.d.ts.map
|
package/dist/release.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"release.d.ts","sourceRoot":"","sources":["../src/release.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"release.d.ts","sourceRoot":"","sources":["../src/release.ts"],"names":[],"mappings":"AASA;;;;;;;;;GASG;AACH,eAAO,MAAM,OAAO,GAAU,mEAM3B;IACD,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB;;;;;;OAMG;IACH,WAAW,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACvD,8DAA8D;IAC9D,WAAW,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACzE,2DAA2D;IAC3D,iBAAiB,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,aAAa,CAAC,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACvG,8DAA8D;IAC9D,KAAK,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,CAAC;CACrC,kBAwNA,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vc-shell/release-config",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.98-rc.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "dist/release-config.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
"dependencies": {
|
|
14
14
|
"chalk": "^2.4.2",
|
|
15
15
|
"cross-spawn": "^7.0.3",
|
|
16
|
+
"lerna": "^9.0.0",
|
|
16
17
|
"mri": "^1.2.0",
|
|
17
18
|
"prompts": "^2.4.2",
|
|
18
19
|
"semver": "^7.5.4",
|
|
@@ -22,12 +23,14 @@
|
|
|
22
23
|
"@types/cross-spawn": "^6.0.6",
|
|
23
24
|
"@types/prompts": "^2.4.7",
|
|
24
25
|
"@types/semver": "^7.5.4",
|
|
25
|
-
"@vc-shell/ts-config": "
|
|
26
|
+
"@vc-shell/ts-config": "1.1.98-rc.0",
|
|
26
27
|
"typescript": "^5.8.3",
|
|
27
28
|
"vite-plugin-dts": "^3.6.4"
|
|
28
29
|
},
|
|
29
30
|
"publishConfig": {
|
|
30
31
|
"access": "public",
|
|
31
32
|
"registry": "https://registry.npmjs.org/"
|
|
32
|
-
}
|
|
33
|
-
|
|
33
|
+
},
|
|
34
|
+
"npmTag": "rc",
|
|
35
|
+
"gitHead": "6f0696dfa3fd8d8e3a47eb130bb2a5adda0418ec"
|
|
36
|
+
}
|