Comparing version 9.2.0 to 9.2.1
/** | ||
* The main entry point of the CLI | ||
* | ||
* @param args - The command-line arguments (e.g. ["major", "--preid=alpha", "-ctpa"]) | ||
*/ | ||
@@ -6,0 +4,0 @@ declare function main(): Promise<void>; |
@@ -118,3 +118,3 @@ var __create = Object.create; | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/vendor/ansi-styles/index.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/ansi-styles/index.js | ||
var ANSI_BACKGROUND_OFFSET = 10; | ||
@@ -305,3 +305,3 @@ var wrapAnsi16 = (offset = 0) => (code) => `\x1B[${code + offset}m`; | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/vendor/supports-color/index.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/supports-color/index.js | ||
var import_node_process = __toESM(require("process"), 1); | ||
@@ -380,3 +380,3 @@ var import_node_os = __toESM(require("os"), 1); | ||
if ("CI" in env) { | ||
if ("GITHUB_ACTIONS" in env) { | ||
if ("GITHUB_ACTIONS" in env || "GITEA_ACTIONS" in env) { | ||
return 3; | ||
@@ -432,3 +432,3 @@ } | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/utilities.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/utilities.js | ||
function stringReplaceAll(string, substring, replacer) { | ||
@@ -463,3 +463,3 @@ let index = string.indexOf(substring); | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/index.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/index.js | ||
var { stdout: stdoutColor, stderr: stderrColor } = supports_color_default; | ||
@@ -619,3 +619,3 @@ var GENERATOR = Symbol("GENERATOR"); | ||
// node_modules/.pnpm/log-symbols@5.1.0/node_modules/log-symbols/index.js | ||
// node_modules/.pnpm/log-symbols@6.0.0/node_modules/log-symbols/index.js | ||
var main = { | ||
@@ -637,3 +637,3 @@ info: source_default.blue("\u2139"), | ||
// package.json | ||
var version = "9.2.0"; | ||
var version = "9.2.1"; | ||
@@ -702,5 +702,7 @@ // src/version-bump.ts | ||
async function promptForNewVersion(operation) { | ||
var _a, _b; | ||
const { oldVersion } = operation.state; | ||
const release = operation.options.release; | ||
const next = getNextVersions(oldVersion, release.preid); | ||
const configCustomVersion = await ((_b = (_a = operation.options).customVersion) == null ? void 0 : _b.call(_a, oldVersion, import_semver2.default)); | ||
const PADDING = 13; | ||
@@ -712,3 +714,3 @@ const answers = await (0, import_prompts.default)([ | ||
message: `Current version ${import_picocolors.default.green(oldVersion)}`, | ||
initial: "next", | ||
initial: configCustomVersion ? "config" : "next", | ||
choices: [ | ||
@@ -719,2 +721,5 @@ { value: "major", title: `${"major".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.major)}` }, | ||
{ value: "next", title: `${"next".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.next)}` }, | ||
...configCustomVersion ? [ | ||
{ value: "config", title: `${"from config".padStart(PADDING, " ")} ${import_picocolors.default.bold(configCustomVersion)}` } | ||
] : [], | ||
{ value: "prepatch", title: `${"pre-patch".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.prepatch)}` }, | ||
@@ -737,3 +742,3 @@ { value: "preminor", title: `${"pre-minor".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.preminor)}` }, | ||
]); | ||
const newVersion = answers.release === "none" ? oldVersion : answers.release === "custom" ? (0, import_semver2.clean)(answers.custom) : next[answers.release]; | ||
const newVersion = answers.release === "none" ? oldVersion : answers.release === "custom" ? (0, import_semver2.clean)(answers.custom) : answers.release === "config" ? (0, import_semver2.clean)(configCustomVersion) : next[answers.release]; | ||
if (!newVersion) | ||
@@ -743,2 +748,3 @@ import_node_process3.default.exit(1); | ||
case "custom": | ||
case "config": | ||
case "next": | ||
@@ -859,3 +865,3 @@ case "none": | ||
// node_modules/.pnpm/detect-newline@4.0.0/node_modules/detect-newline/index.js | ||
// node_modules/.pnpm/detect-newline@4.0.1/node_modules/detect-newline/index.js | ||
function detectNewline(string) { | ||
@@ -1063,3 +1069,14 @@ if (typeof string !== "string") { | ||
throw new Error("Cannot prompt for the version number because input or output has been disabled."); | ||
return { release, commit, tag, push, files, cwd, interface: ui, ignoreScripts, execute }; | ||
return { | ||
release, | ||
commit, | ||
tag, | ||
push, | ||
files, | ||
cwd, | ||
interface: ui, | ||
ignoreScripts, | ||
execute, | ||
customVersion: raw.customVersion | ||
}; | ||
} | ||
@@ -1066,0 +1083,0 @@ |
@@ -1,2 +0,2 @@ | ||
import { ReleaseType } from 'semver'; | ||
import _semver, { ReleaseType } from 'semver'; | ||
export { ReleaseType } from 'semver'; | ||
@@ -179,2 +179,6 @@ | ||
recursive?: boolean; | ||
/** | ||
* Custom function to provide the version number | ||
*/ | ||
customVersion?: (currentVersion: string, semver: typeof _semver) => Promise<string | void> | string | void; | ||
} | ||
@@ -262,2 +266,3 @@ /** | ||
execute?: string; | ||
customVersion?: VersionBumpOptions['customVersion']; | ||
} | ||
@@ -344,2 +349,2 @@ | ||
export { InterfaceOptions, NpmScript, ProgressEvent, VersionBumpOptions, VersionBumpProgress, VersionBumpResults, bumpConfigDefaults, versionBump as default, defineConfig, loadBumpConfig, versionBump, versionBumpInfo }; | ||
export { type InterfaceOptions, NpmScript, ProgressEvent, type VersionBumpOptions, type VersionBumpProgress, type VersionBumpResults, bumpConfigDefaults, versionBump as default, defineConfig, loadBumpConfig, versionBump, versionBumpInfo }; |
@@ -130,3 +130,3 @@ var __create = Object.create; | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/vendor/ansi-styles/index.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/ansi-styles/index.js | ||
var ANSI_BACKGROUND_OFFSET = 10; | ||
@@ -317,3 +317,3 @@ var wrapAnsi16 = (offset = 0) => (code) => `\x1B[${code + offset}m`; | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/vendor/supports-color/index.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/supports-color/index.js | ||
var import_node_process = __toESM(require("process"), 1); | ||
@@ -392,3 +392,3 @@ var import_node_os = __toESM(require("os"), 1); | ||
if ("CI" in env) { | ||
if ("GITHUB_ACTIONS" in env) { | ||
if ("GITHUB_ACTIONS" in env || "GITEA_ACTIONS" in env) { | ||
return 3; | ||
@@ -444,3 +444,3 @@ } | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/utilities.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/utilities.js | ||
function stringReplaceAll(string, substring, replacer) { | ||
@@ -475,3 +475,3 @@ let index = string.indexOf(substring); | ||
// node_modules/.pnpm/chalk@5.2.0/node_modules/chalk/source/index.js | ||
// node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/index.js | ||
var { stdout: stdoutColor, stderr: stderrColor } = supports_color_default; | ||
@@ -631,3 +631,3 @@ var GENERATOR = Symbol("GENERATOR"); | ||
// node_modules/.pnpm/log-symbols@5.1.0/node_modules/log-symbols/index.js | ||
// node_modules/.pnpm/log-symbols@6.0.0/node_modules/log-symbols/index.js | ||
var main = { | ||
@@ -707,5 +707,7 @@ info: source_default.blue("\u2139"), | ||
async function promptForNewVersion(operation) { | ||
var _a, _b; | ||
const { oldVersion } = operation.state; | ||
const release = operation.options.release; | ||
const next = getNextVersions(oldVersion, release.preid); | ||
const configCustomVersion = await ((_b = (_a = operation.options).customVersion) == null ? void 0 : _b.call(_a, oldVersion, import_semver2.default)); | ||
const PADDING = 13; | ||
@@ -717,3 +719,3 @@ const answers = await (0, import_prompts.default)([ | ||
message: `Current version ${import_picocolors.default.green(oldVersion)}`, | ||
initial: "next", | ||
initial: configCustomVersion ? "config" : "next", | ||
choices: [ | ||
@@ -724,2 +726,5 @@ { value: "major", title: `${"major".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.major)}` }, | ||
{ value: "next", title: `${"next".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.next)}` }, | ||
...configCustomVersion ? [ | ||
{ value: "config", title: `${"from config".padStart(PADDING, " ")} ${import_picocolors.default.bold(configCustomVersion)}` } | ||
] : [], | ||
{ value: "prepatch", title: `${"pre-patch".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.prepatch)}` }, | ||
@@ -742,3 +747,3 @@ { value: "preminor", title: `${"pre-minor".padStart(PADDING, " ")} ${import_picocolors.default.bold(next.preminor)}` }, | ||
]); | ||
const newVersion = answers.release === "none" ? oldVersion : answers.release === "custom" ? (0, import_semver2.clean)(answers.custom) : next[answers.release]; | ||
const newVersion = answers.release === "none" ? oldVersion : answers.release === "custom" ? (0, import_semver2.clean)(answers.custom) : answers.release === "config" ? (0, import_semver2.clean)(configCustomVersion) : next[answers.release]; | ||
if (!newVersion) | ||
@@ -748,2 +753,3 @@ import_node_process3.default.exit(1); | ||
case "custom": | ||
case "config": | ||
case "next": | ||
@@ -864,3 +870,3 @@ case "none": | ||
// node_modules/.pnpm/detect-newline@4.0.0/node_modules/detect-newline/index.js | ||
// node_modules/.pnpm/detect-newline@4.0.1/node_modules/detect-newline/index.js | ||
function detectNewline(string) { | ||
@@ -1087,3 +1093,14 @@ if (typeof string !== "string") { | ||
throw new Error("Cannot prompt for the version number because input or output has been disabled."); | ||
return { release, commit, tag, push, files, cwd, interface: ui, ignoreScripts, execute }; | ||
return { | ||
release, | ||
commit, | ||
tag, | ||
push, | ||
files, | ||
cwd, | ||
interface: ui, | ||
ignoreScripts, | ||
execute, | ||
customVersion: raw.customVersion | ||
}; | ||
} | ||
@@ -1090,0 +1107,0 @@ |
{ | ||
"name": "bumpp", | ||
"version": "9.2.0", | ||
"packageManager": "pnpm@8.6.12", | ||
"version": "9.2.1", | ||
"packageManager": "pnpm@8.12.0", | ||
"description": "Bump version, commit changes, tag, and push to Git", | ||
@@ -61,5 +61,5 @@ "author": { | ||
"@jsdevtools/ez-spawn": "^3.0.4", | ||
"c12": "^1.4.2", | ||
"c12": "^1.5.1", | ||
"cac": "^6.7.14", | ||
"fast-glob": "^3.3.1", | ||
"fast-glob": "^3.3.2", | ||
"prompts": "^2.4.2", | ||
@@ -69,17 +69,17 @@ "semver": "^7.5.4" | ||
"devDependencies": { | ||
"@antfu/eslint-config": "^0.40.2", | ||
"@types/node": "^20.5.1", | ||
"@types/prompts": "^2.4.4", | ||
"@types/semver": "^7.5.0", | ||
"@antfu/eslint-config": "^2.4.3", | ||
"@types/node": "^20.10.4", | ||
"@types/prompts": "^2.4.9", | ||
"@types/semver": "^7.5.6", | ||
"detect-indent": "^7.0.1", | ||
"detect-newline": "^4.0.0", | ||
"eslint": "^8.47.0", | ||
"esno": "^0.17.0", | ||
"log-symbols": "^5.1.0", | ||
"detect-newline": "^4.0.1", | ||
"eslint": "^8.55.0", | ||
"esno": "^4.0.0", | ||
"log-symbols": "^6.0.0", | ||
"npm-check": "^6.0.1", | ||
"picocolors": "^1.0.0", | ||
"rimraf": "^5.0.1", | ||
"tsup": "^7.2.0", | ||
"typescript": "^5.1.6" | ||
"rimraf": "^5.0.5", | ||
"tsup": "^8.0.1", | ||
"typescript": "^5.3.3" | ||
} | ||
} |
@@ -16,3 +16,3 @@ # bumpp | ||
- `-r` or `--recursive` to bump all packages in the monorepo. | ||
- Conventional Commits by default. | ||
- Conventional Commits by default. | ||
- Supports config file `bumpp.config.ts`: | ||
@@ -19,0 +19,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
169559
4435
Updatedc12@^1.5.1
Updatedfast-glob@^3.3.2