bumpp 9.8.0 → 9.8.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/README.md +2 -6
- package/dist/cli/index.js +7 -11
- package/dist/cli/index.mjs +8 -8
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -7,14 +7,13 @@ Forked from [`version-bump-prompt`](https://github.com/JS-DevTools/version-bump-
|
|
|
7
7
|
###### Changes in this fork
|
|
8
8
|
|
|
9
9
|
- Renamed to `bumpp` - so you can use `npx bumpp` directly.
|
|
10
|
-
- Ships ESM and CJS bundles.
|
|
11
|
-
- Add a new argument `--execute` to execute the command, or execute a function before committing.
|
|
12
10
|
- Use the current version's `preid` when available.
|
|
13
11
|
- Confirmation before bumping.
|
|
14
12
|
- Enable `--commit` `--tag` `--push` by default. (opt-out by `--no-push`, etc.)
|
|
15
|
-
- `--sign` to sign the commit and tag.
|
|
16
13
|
- `-r` or `--recursive` to bump all packages in the monorepo.
|
|
14
|
+
- `--execute` to execute the command, or execute a function before committing.
|
|
17
15
|
- Conventional Commits by default.
|
|
16
|
+
- Ships ESM and CJS bundles.
|
|
18
17
|
- Supports config file `bump.config.ts`:
|
|
19
18
|
|
|
20
19
|
```ts
|
|
@@ -23,8 +22,5 @@ import { defineConfig } from 'bumpp'
|
|
|
23
22
|
|
|
24
23
|
export default defineConfig({
|
|
25
24
|
// ...options
|
|
26
|
-
execute(config) {
|
|
27
|
-
// ...`execute` could receive a function here
|
|
28
|
-
}
|
|
29
25
|
})
|
|
30
26
|
```
|
package/dist/cli/index.js
CHANGED
|
@@ -138,6 +138,7 @@ __export(cli_exports, {
|
|
|
138
138
|
});
|
|
139
139
|
module.exports = __toCommonJS(cli_exports);
|
|
140
140
|
var import_node_process8 = __toESM(require("process"));
|
|
141
|
+
var ezSpawn5 = __toESM(require("@jsdevtools/ez-spawn"));
|
|
141
142
|
|
|
142
143
|
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/ansi-styles/index.js
|
|
143
144
|
var ANSI_BACKGROUND_OFFSET = 10;
|
|
@@ -651,12 +652,6 @@ var fallback = {
|
|
|
651
652
|
var logSymbols = isUnicodeSupported() ? main : fallback;
|
|
652
653
|
var log_symbols_default = logSymbols;
|
|
653
654
|
|
|
654
|
-
// src/cli/index.ts
|
|
655
|
-
var ezSpawn5 = __toESM(require("@jsdevtools/ez-spawn"));
|
|
656
|
-
|
|
657
|
-
// package.json
|
|
658
|
-
var version = "9.8.0";
|
|
659
|
-
|
|
660
655
|
// src/version-bump.ts
|
|
661
656
|
var import_node_process5 = __toESM(require("process"));
|
|
662
657
|
var ezSpawn4 = __toESM(require("@jsdevtools/ez-spawn"));
|
|
@@ -1361,6 +1356,9 @@ var import_cac = __toESM(require("cac"));
|
|
|
1361
1356
|
var import_picocolors4 = __toESM(require_picocolors());
|
|
1362
1357
|
var import_semver3 = require("semver");
|
|
1363
1358
|
|
|
1359
|
+
// package.json
|
|
1360
|
+
var version = "9.8.1";
|
|
1361
|
+
|
|
1364
1362
|
// src/config.ts
|
|
1365
1363
|
var import_node_path2 = require("path");
|
|
1366
1364
|
var import_node_process6 = __toESM(require("process"));
|
|
@@ -1439,6 +1437,7 @@ async function parseArgs() {
|
|
|
1439
1437
|
ignoreScripts: args.ignoreScripts,
|
|
1440
1438
|
currentVersion: args.currentVersion,
|
|
1441
1439
|
execute: args.execute,
|
|
1440
|
+
printCommits: args.printCommits,
|
|
1442
1441
|
recursive: args.recursive
|
|
1443
1442
|
})
|
|
1444
1443
|
};
|
|
@@ -1458,7 +1457,7 @@ async function parseArgs() {
|
|
|
1458
1457
|
}
|
|
1459
1458
|
function loadCliArgs(argv = import_node_process7.default.argv) {
|
|
1460
1459
|
const cli = (0, import_cac.default)("bumpp");
|
|
1461
|
-
cli.version(version).usage("[...files]").option("--preid <preid>", "ID for prerelease").option("--all", `Include all files (default: ${bumpConfigDefaults.all})`).option("--no-git-check", `Skip git check`, { default: bumpConfigDefaults.noGitCheck }).option("-c, --commit [msg]", "Commit message", { default: true }).option("--no-commit", "Skip commit", { default: false }).option("-t, --tag [tag]", "Tag name", { default: true }).option("--no-tag", "Skip tag", { default: false }).option("--sign", "Sign commit and tag").option("-p, --push", `Push to remote (default: ${bumpConfigDefaults.push})`).option("-y, --yes", `Skip confirmation (default: ${!bumpConfigDefaults.confirm})`).option("-r, --recursive", `Bump package.json files recursively (default: ${bumpConfigDefaults.recursive})`).option("--no-verify", "Skip git verification").option("--ignore-scripts", `Ignore scripts (default: ${bumpConfigDefaults.ignoreScripts})`).option("-q, --quiet", "Quiet mode").option("
|
|
1460
|
+
cli.version(version).usage("[...files]").option("--preid <preid>", "ID for prerelease").option("--all", `Include all files (default: ${bumpConfigDefaults.all})`).option("--no-git-check", `Skip git check`, { default: bumpConfigDefaults.noGitCheck }).option("-c, --commit [msg]", "Commit message", { default: true }).option("--no-commit", "Skip commit", { default: false }).option("-t, --tag [tag]", "Tag name", { default: true }).option("--no-tag", "Skip tag", { default: false }).option("--sign", "Sign commit and tag").option("-p, --push", `Push to remote (default: ${bumpConfigDefaults.push})`).option("-y, --yes", `Skip confirmation (default: ${!bumpConfigDefaults.confirm})`).option("-r, --recursive", `Bump package.json files recursively (default: ${bumpConfigDefaults.recursive})`).option("--no-verify", "Skip git verification").option("--ignore-scripts", `Ignore scripts (default: ${bumpConfigDefaults.ignoreScripts})`).option("-q, --quiet", "Quiet mode").option("--current-version <version>", "Current version").option("--print-commits", "Print recent commits").option("-x, --execute <command>", "Commands to execute after version bumps").help();
|
|
1462
1461
|
const result = cli.parse(argv);
|
|
1463
1462
|
const rawArgs = cli.rawArgs;
|
|
1464
1463
|
const args = result.options;
|
|
@@ -1486,10 +1485,7 @@ async function main2() {
|
|
|
1486
1485
|
import_node_process8.default.on("uncaughtException", errorHandler2);
|
|
1487
1486
|
import_node_process8.default.on("unhandledRejection", errorHandler2);
|
|
1488
1487
|
const { help, version: version2, quiet, options } = await parseArgs();
|
|
1489
|
-
if (help) {
|
|
1490
|
-
import_node_process8.default.exit(0 /* Success */);
|
|
1491
|
-
} else if (version2) {
|
|
1492
|
-
console.log(version);
|
|
1488
|
+
if (help || version2) {
|
|
1493
1489
|
import_node_process8.default.exit(0 /* Success */);
|
|
1494
1490
|
} else {
|
|
1495
1491
|
if (!options.all && !options.noGitCheck) {
|
package/dist/cli/index.mjs
CHANGED
|
@@ -16,14 +16,16 @@ import {
|
|
|
16
16
|
import process2 from "node:process";
|
|
17
17
|
import * as ezSpawn from "@jsdevtools/ez-spawn";
|
|
18
18
|
|
|
19
|
-
// package.json
|
|
20
|
-
var version = "9.8.0";
|
|
21
|
-
|
|
22
19
|
// src/cli/parse-args.ts
|
|
23
20
|
var import_picocolors = __toESM(require_picocolors());
|
|
24
21
|
import process from "node:process";
|
|
25
22
|
import cac from "cac";
|
|
26
23
|
import { valid as isValidVersion } from "semver";
|
|
24
|
+
|
|
25
|
+
// package.json
|
|
26
|
+
var version = "9.8.1";
|
|
27
|
+
|
|
28
|
+
// src/cli/parse-args.ts
|
|
27
29
|
async function parseArgs() {
|
|
28
30
|
var _a;
|
|
29
31
|
try {
|
|
@@ -46,6 +48,7 @@ async function parseArgs() {
|
|
|
46
48
|
ignoreScripts: args.ignoreScripts,
|
|
47
49
|
currentVersion: args.currentVersion,
|
|
48
50
|
execute: args.execute,
|
|
51
|
+
printCommits: args.printCommits,
|
|
49
52
|
recursive: args.recursive
|
|
50
53
|
})
|
|
51
54
|
};
|
|
@@ -65,7 +68,7 @@ async function parseArgs() {
|
|
|
65
68
|
}
|
|
66
69
|
function loadCliArgs(argv = process.argv) {
|
|
67
70
|
const cli = cac("bumpp");
|
|
68
|
-
cli.version(version).usage("[...files]").option("--preid <preid>", "ID for prerelease").option("--all", `Include all files (default: ${bumpConfigDefaults.all})`).option("--no-git-check", `Skip git check`, { default: bumpConfigDefaults.noGitCheck }).option("-c, --commit [msg]", "Commit message", { default: true }).option("--no-commit", "Skip commit", { default: false }).option("-t, --tag [tag]", "Tag name", { default: true }).option("--no-tag", "Skip tag", { default: false }).option("--sign", "Sign commit and tag").option("-p, --push", `Push to remote (default: ${bumpConfigDefaults.push})`).option("-y, --yes", `Skip confirmation (default: ${!bumpConfigDefaults.confirm})`).option("-r, --recursive", `Bump package.json files recursively (default: ${bumpConfigDefaults.recursive})`).option("--no-verify", "Skip git verification").option("--ignore-scripts", `Ignore scripts (default: ${bumpConfigDefaults.ignoreScripts})`).option("-q, --quiet", "Quiet mode").option("
|
|
71
|
+
cli.version(version).usage("[...files]").option("--preid <preid>", "ID for prerelease").option("--all", `Include all files (default: ${bumpConfigDefaults.all})`).option("--no-git-check", `Skip git check`, { default: bumpConfigDefaults.noGitCheck }).option("-c, --commit [msg]", "Commit message", { default: true }).option("--no-commit", "Skip commit", { default: false }).option("-t, --tag [tag]", "Tag name", { default: true }).option("--no-tag", "Skip tag", { default: false }).option("--sign", "Sign commit and tag").option("-p, --push", `Push to remote (default: ${bumpConfigDefaults.push})`).option("-y, --yes", `Skip confirmation (default: ${!bumpConfigDefaults.confirm})`).option("-r, --recursive", `Bump package.json files recursively (default: ${bumpConfigDefaults.recursive})`).option("--no-verify", "Skip git verification").option("--ignore-scripts", `Ignore scripts (default: ${bumpConfigDefaults.ignoreScripts})`).option("-q, --quiet", "Quiet mode").option("--current-version <version>", "Current version").option("--print-commits", "Print recent commits").option("-x, --execute <command>", "Commands to execute after version bumps").help();
|
|
69
72
|
const result = cli.parse(argv);
|
|
70
73
|
const rawArgs = cli.rawArgs;
|
|
71
74
|
const args = result.options;
|
|
@@ -93,10 +96,7 @@ async function main() {
|
|
|
93
96
|
process2.on("uncaughtException", errorHandler2);
|
|
94
97
|
process2.on("unhandledRejection", errorHandler2);
|
|
95
98
|
const { help, version: version2, quiet, options } = await parseArgs();
|
|
96
|
-
if (help) {
|
|
97
|
-
process2.exit(0 /* Success */);
|
|
98
|
-
} else if (version2) {
|
|
99
|
-
console.log(version);
|
|
99
|
+
if (help || version2) {
|
|
100
100
|
process2.exit(0 /* Success */);
|
|
101
101
|
} else {
|
|
102
102
|
if (!options.all && !options.noGitCheck) {
|