Comparing version 9.7.1 to 9.8.0
@@ -61,16 +61,15 @@ var __create = Object.create; | ||
// node_modules/.pnpm/picocolors@1.1.0/node_modules/picocolors/picocolors.js | ||
// node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js | ||
var require_picocolors = __commonJS({ | ||
"node_modules/.pnpm/picocolors@1.1.0/node_modules/picocolors/picocolors.js"(exports2, module2) { | ||
var argv = process.argv || []; | ||
var env2 = process.env; | ||
var isColorSupported = !("NO_COLOR" in env2 || argv.includes("--no-color")) && ("FORCE_COLOR" in env2 || argv.includes("--color") || process.platform === "win32" || require != null && require("tty").isatty(1) && env2.TERM !== "dumb" || "CI" in env2); | ||
"node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js"(exports2, module2) { | ||
var p = process || {}; | ||
var argv = p.argv || []; | ||
var env2 = p.env || {}; | ||
var isColorSupported = !(!!env2.NO_COLOR || argv.includes("--no-color")) && (!!env2.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env2.TERM !== "dumb" || !!env2.CI); | ||
var formatter = (open, close, replace = open) => (input) => { | ||
let string = "" + input; | ||
let index = string.indexOf(close, open.length); | ||
let string = "" + input, index = string.indexOf(close, open.length); | ||
return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close; | ||
}; | ||
var replaceClose = (string, close, replace, index) => { | ||
let result = ""; | ||
let cursor = 0; | ||
let result = "", cursor = 0; | ||
do { | ||
@@ -84,46 +83,46 @@ result += string.substring(cursor, index) + replace; | ||
var createColors = (enabled = isColorSupported) => { | ||
let init = enabled ? formatter : () => String; | ||
let f = enabled ? formatter : () => String; | ||
return { | ||
isColorSupported: enabled, | ||
reset: init("\x1B[0m", "\x1B[0m"), | ||
bold: init("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"), | ||
dim: init("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"), | ||
italic: init("\x1B[3m", "\x1B[23m"), | ||
underline: init("\x1B[4m", "\x1B[24m"), | ||
inverse: init("\x1B[7m", "\x1B[27m"), | ||
hidden: init("\x1B[8m", "\x1B[28m"), | ||
strikethrough: init("\x1B[9m", "\x1B[29m"), | ||
black: init("\x1B[30m", "\x1B[39m"), | ||
red: init("\x1B[31m", "\x1B[39m"), | ||
green: init("\x1B[32m", "\x1B[39m"), | ||
yellow: init("\x1B[33m", "\x1B[39m"), | ||
blue: init("\x1B[34m", "\x1B[39m"), | ||
magenta: init("\x1B[35m", "\x1B[39m"), | ||
cyan: init("\x1B[36m", "\x1B[39m"), | ||
white: init("\x1B[37m", "\x1B[39m"), | ||
gray: init("\x1B[90m", "\x1B[39m"), | ||
bgBlack: init("\x1B[40m", "\x1B[49m"), | ||
bgRed: init("\x1B[41m", "\x1B[49m"), | ||
bgGreen: init("\x1B[42m", "\x1B[49m"), | ||
bgYellow: init("\x1B[43m", "\x1B[49m"), | ||
bgBlue: init("\x1B[44m", "\x1B[49m"), | ||
bgMagenta: init("\x1B[45m", "\x1B[49m"), | ||
bgCyan: init("\x1B[46m", "\x1B[49m"), | ||
bgWhite: init("\x1B[47m", "\x1B[49m"), | ||
blackBright: init("\x1B[90m", "\x1B[39m"), | ||
redBright: init("\x1B[91m", "\x1B[39m"), | ||
greenBright: init("\x1B[92m", "\x1B[39m"), | ||
yellowBright: init("\x1B[93m", "\x1B[39m"), | ||
blueBright: init("\x1B[94m", "\x1B[39m"), | ||
magentaBright: init("\x1B[95m", "\x1B[39m"), | ||
cyanBright: init("\x1B[96m", "\x1B[39m"), | ||
whiteBright: init("\x1B[97m", "\x1B[39m"), | ||
bgBlackBright: init("\x1B[100m", "\x1B[49m"), | ||
bgRedBright: init("\x1B[101m", "\x1B[49m"), | ||
bgGreenBright: init("\x1B[102m", "\x1B[49m"), | ||
bgYellowBright: init("\x1B[103m", "\x1B[49m"), | ||
bgBlueBright: init("\x1B[104m", "\x1B[49m"), | ||
bgMagentaBright: init("\x1B[105m", "\x1B[49m"), | ||
bgCyanBright: init("\x1B[106m", "\x1B[49m"), | ||
bgWhiteBright: init("\x1B[107m", "\x1B[49m") | ||
reset: f("\x1B[0m", "\x1B[0m"), | ||
bold: f("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"), | ||
dim: f("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"), | ||
italic: f("\x1B[3m", "\x1B[23m"), | ||
underline: f("\x1B[4m", "\x1B[24m"), | ||
inverse: f("\x1B[7m", "\x1B[27m"), | ||
hidden: f("\x1B[8m", "\x1B[28m"), | ||
strikethrough: f("\x1B[9m", "\x1B[29m"), | ||
black: f("\x1B[30m", "\x1B[39m"), | ||
red: f("\x1B[31m", "\x1B[39m"), | ||
green: f("\x1B[32m", "\x1B[39m"), | ||
yellow: f("\x1B[33m", "\x1B[39m"), | ||
blue: f("\x1B[34m", "\x1B[39m"), | ||
magenta: f("\x1B[35m", "\x1B[39m"), | ||
cyan: f("\x1B[36m", "\x1B[39m"), | ||
white: f("\x1B[37m", "\x1B[39m"), | ||
gray: f("\x1B[90m", "\x1B[39m"), | ||
bgBlack: f("\x1B[40m", "\x1B[49m"), | ||
bgRed: f("\x1B[41m", "\x1B[49m"), | ||
bgGreen: f("\x1B[42m", "\x1B[49m"), | ||
bgYellow: f("\x1B[43m", "\x1B[49m"), | ||
bgBlue: f("\x1B[44m", "\x1B[49m"), | ||
bgMagenta: f("\x1B[45m", "\x1B[49m"), | ||
bgCyan: f("\x1B[46m", "\x1B[49m"), | ||
bgWhite: f("\x1B[47m", "\x1B[49m"), | ||
blackBright: f("\x1B[90m", "\x1B[39m"), | ||
redBright: f("\x1B[91m", "\x1B[39m"), | ||
greenBright: f("\x1B[92m", "\x1B[39m"), | ||
yellowBright: f("\x1B[93m", "\x1B[39m"), | ||
blueBright: f("\x1B[94m", "\x1B[39m"), | ||
magentaBright: f("\x1B[95m", "\x1B[39m"), | ||
cyanBright: f("\x1B[96m", "\x1B[39m"), | ||
whiteBright: f("\x1B[97m", "\x1B[39m"), | ||
bgBlackBright: f("\x1B[100m", "\x1B[49m"), | ||
bgRedBright: f("\x1B[101m", "\x1B[49m"), | ||
bgGreenBright: f("\x1B[102m", "\x1B[49m"), | ||
bgYellowBright: f("\x1B[103m", "\x1B[49m"), | ||
bgBlueBright: f("\x1B[104m", "\x1B[49m"), | ||
bgMagentaBright: f("\x1B[105m", "\x1B[49m"), | ||
bgCyanBright: f("\x1B[106m", "\x1B[49m"), | ||
bgWhiteBright: f("\x1B[107m", "\x1B[49m") | ||
}; | ||
@@ -661,3 +660,3 @@ }; | ||
// package.json | ||
var version = "9.7.1"; | ||
var version = "9.8.0"; | ||
@@ -1054,4 +1053,4 @@ // src/version-bump.ts | ||
var import_node_process4 = __toESM(require("process")); | ||
var import_fast_glob = __toESM(require("fast-glob")); | ||
var import_js_yaml = __toESM(require("js-yaml")); | ||
var import_tinyglobby = require("tinyglobby"); | ||
async function normalizeOptions(raw) { | ||
@@ -1108,3 +1107,3 @@ var _a, _b, _d; | ||
} | ||
const files = await (0, import_fast_glob.default)( | ||
const files = await (0, import_tinyglobby.glob)( | ||
raw.files, | ||
@@ -1114,2 +1113,3 @@ { | ||
onlyFiles: true, | ||
expandDirectories: false, | ||
ignore: [ | ||
@@ -1332,5 +1332,9 @@ "**/{.git,node_modules,bower_components,__tests__,fixtures,fixture}/**" | ||
if (operation.options.execute) { | ||
console.log(log_symbols_default.info, "Executing script", operation.options.execute); | ||
await ezSpawn4.async(operation.options.execute, { stdio: "inherit" }); | ||
console.log(log_symbols_default.success, "Script finished"); | ||
if (typeof operation.options.execute === "function") { | ||
await operation.options.execute(operation); | ||
} else { | ||
console.log(log_symbols_default.info, "Executing script", operation.options.execute); | ||
await ezSpawn4.async(operation.options.execute, { stdio: "inherit" }); | ||
console.log(log_symbols_default.success, "Script finished"); | ||
} | ||
} | ||
@@ -1352,3 +1356,3 @@ await runNpmScript("version" /* Version */, operation); | ||
if (operation.options.execute) | ||
console.log(` execute ${import_picocolors3.default.bold(operation.options.execute)}`); | ||
console.log(` execute ${import_picocolors3.default.bold(typeof operation.options.execute === "function" ? "function" : operation.options.execute)}`); | ||
if (operation.options.push) | ||
@@ -1355,0 +1359,0 @@ console.log(` push ${import_picocolors3.default.cyan(import_picocolors3.default.bold("yes"))}`); |
@@ -5,3 +5,58 @@ import _semver, { ReleaseType as ReleaseType$1 } from 'semver'; | ||
interface Interface { | ||
input?: NodeJS.ReadableStream | NodeJS.ReadStream | false; | ||
output?: NodeJS.WritableStream | NodeJS.WriteStream | false; | ||
[key: string]: unknown; | ||
} | ||
/** | ||
* A specific version release. | ||
*/ | ||
interface VersionRelease { | ||
type: 'version'; | ||
version: string; | ||
} | ||
/** | ||
* Prompt the user for the release number. | ||
*/ | ||
interface PromptRelease { | ||
type: 'prompt'; | ||
preid: string; | ||
} | ||
/** | ||
* A bump release, relative to the current version number. | ||
*/ | ||
interface BumpRelease { | ||
type: ReleaseType; | ||
preid: string; | ||
} | ||
/** | ||
* One of the possible Release types. | ||
*/ | ||
type Release = VersionRelease | PromptRelease | BumpRelease; | ||
/** | ||
* Normalized and sanitized options | ||
*/ | ||
interface NormalizedOptions { | ||
release: Release; | ||
commit?: { | ||
message: string; | ||
noVerify: boolean; | ||
all: boolean; | ||
}; | ||
tag?: { | ||
name: string; | ||
}; | ||
sign?: boolean; | ||
push: boolean; | ||
files: string[]; | ||
cwd: string; | ||
interface: Interface; | ||
ignoreScripts: boolean; | ||
execute?: string | ((config?: Operation) => void | PromiseLike<void>); | ||
printCommits?: boolean; | ||
customVersion?: VersionBumpOptions['customVersion']; | ||
currentVersion?: string; | ||
} | ||
/** | ||
* Information about the work that was performed by the `versionBump()` function. | ||
@@ -73,3 +128,51 @@ */ | ||
interface OperationState { | ||
release: ReleaseType | undefined; | ||
currentVersionSource: string; | ||
currentVersion: string; | ||
newVersion: string; | ||
commitMessage: string; | ||
tagName: string; | ||
updatedFiles: string[]; | ||
skippedFiles: string[]; | ||
} | ||
interface UpdateOperationState extends Partial<OperationState> { | ||
event?: ProgressEvent; | ||
script?: NpmScript; | ||
} | ||
/** | ||
* All of the inputs, outputs, and state of a single `versionBump()` call. | ||
*/ | ||
declare class Operation { | ||
/** | ||
* The options for this operation. | ||
*/ | ||
options: NormalizedOptions; | ||
/** | ||
* The current state of the operation. | ||
*/ | ||
readonly state: Readonly<OperationState>; | ||
/** | ||
* The results of the operation. | ||
*/ | ||
get results(): VersionBumpResults; | ||
/** | ||
* The callback that's used to report the progress of the operation. | ||
*/ | ||
private readonly _progress?; | ||
/** | ||
* Private constructor. Use the `Operation.start()` static method instead. | ||
*/ | ||
private constructor(); | ||
/** | ||
* Starts a new `versionBump()` operation. | ||
*/ | ||
static start(input: VersionBumpOptions): Promise<Operation>; | ||
/** | ||
* Updates the operation state and results, and reports the updated progress to the user. | ||
*/ | ||
update({ event, script, ...newState }: UpdateOperationState): this; | ||
} | ||
/** | ||
* Options for the `versionBump()` function. | ||
@@ -192,3 +295,3 @@ */ | ||
*/ | ||
execute?: string; | ||
execute?: string | ((config?: Operation) => void | PromiseLike<void>); | ||
/** | ||
@@ -241,106 +344,3 @@ * Bump the files recursively for monorepo. Only works without `files` option. | ||
interface Interface { | ||
input?: NodeJS.ReadableStream | NodeJS.ReadStream | false; | ||
output?: NodeJS.WritableStream | NodeJS.WriteStream | false; | ||
[key: string]: unknown; | ||
} | ||
/** | ||
* A specific version release. | ||
*/ | ||
interface VersionRelease { | ||
type: 'version'; | ||
version: string; | ||
} | ||
/** | ||
* Prompt the user for the release number. | ||
*/ | ||
interface PromptRelease { | ||
type: 'prompt'; | ||
preid: string; | ||
} | ||
/** | ||
* A bump release, relative to the current version number. | ||
*/ | ||
interface BumpRelease { | ||
type: ReleaseType; | ||
preid: string; | ||
} | ||
/** | ||
* One of the possible Release types. | ||
*/ | ||
type Release = VersionRelease | PromptRelease | BumpRelease; | ||
/** | ||
* Normalized and sanitized options | ||
*/ | ||
interface NormalizedOptions { | ||
release: Release; | ||
commit?: { | ||
message: string; | ||
noVerify: boolean; | ||
all: boolean; | ||
}; | ||
tag?: { | ||
name: string; | ||
}; | ||
sign?: boolean; | ||
push: boolean; | ||
files: string[]; | ||
cwd: string; | ||
interface: Interface; | ||
ignoreScripts: boolean; | ||
execute?: string; | ||
printCommits?: boolean; | ||
customVersion?: VersionBumpOptions['customVersion']; | ||
currentVersion?: string; | ||
} | ||
interface OperationState { | ||
release: ReleaseType | undefined; | ||
currentVersionSource: string; | ||
currentVersion: string; | ||
newVersion: string; | ||
commitMessage: string; | ||
tagName: string; | ||
updatedFiles: string[]; | ||
skippedFiles: string[]; | ||
} | ||
interface UpdateOperationState extends Partial<OperationState> { | ||
event?: ProgressEvent; | ||
script?: NpmScript; | ||
} | ||
/** | ||
* All of the inputs, outputs, and state of a single `versionBump()` call. | ||
*/ | ||
declare class Operation { | ||
/** | ||
* The options for this operation. | ||
*/ | ||
options: NormalizedOptions; | ||
/** | ||
* The current state of the operation. | ||
*/ | ||
readonly state: Readonly<OperationState>; | ||
/** | ||
* The results of the operation. | ||
*/ | ||
get results(): VersionBumpResults; | ||
/** | ||
* The callback that's used to report the progress of the operation. | ||
*/ | ||
private readonly _progress?; | ||
/** | ||
* Private constructor. Use the `Operation.start()` static method instead. | ||
*/ | ||
private constructor(); | ||
/** | ||
* Starts a new `versionBump()` operation. | ||
*/ | ||
static start(input: VersionBumpOptions): Promise<Operation>; | ||
/** | ||
* Updates the operation state and results, and reports the updated progress to the user. | ||
*/ | ||
update({ event, script, ...newState }: UpdateOperationState): this; | ||
} | ||
/** | ||
* Prompts the user for a version number and updates package.json and package-lock.json. | ||
@@ -347,0 +347,0 @@ * |
@@ -61,16 +61,15 @@ var __create = Object.create; | ||
// node_modules/.pnpm/picocolors@1.1.0/node_modules/picocolors/picocolors.js | ||
// node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js | ||
var require_picocolors = __commonJS({ | ||
"node_modules/.pnpm/picocolors@1.1.0/node_modules/picocolors/picocolors.js"(exports2, module2) { | ||
var argv = process.argv || []; | ||
var env2 = process.env; | ||
var isColorSupported = !("NO_COLOR" in env2 || argv.includes("--no-color")) && ("FORCE_COLOR" in env2 || argv.includes("--color") || process.platform === "win32" || require != null && require("tty").isatty(1) && env2.TERM !== "dumb" || "CI" in env2); | ||
"node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js"(exports2, module2) { | ||
var p = process || {}; | ||
var argv = p.argv || []; | ||
var env2 = p.env || {}; | ||
var isColorSupported = !(!!env2.NO_COLOR || argv.includes("--no-color")) && (!!env2.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env2.TERM !== "dumb" || !!env2.CI); | ||
var formatter = (open, close, replace = open) => (input) => { | ||
let string = "" + input; | ||
let index = string.indexOf(close, open.length); | ||
let string = "" + input, index = string.indexOf(close, open.length); | ||
return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close; | ||
}; | ||
var replaceClose = (string, close, replace, index) => { | ||
let result = ""; | ||
let cursor = 0; | ||
let result = "", cursor = 0; | ||
do { | ||
@@ -84,46 +83,46 @@ result += string.substring(cursor, index) + replace; | ||
var createColors = (enabled = isColorSupported) => { | ||
let init = enabled ? formatter : () => String; | ||
let f = enabled ? formatter : () => String; | ||
return { | ||
isColorSupported: enabled, | ||
reset: init("\x1B[0m", "\x1B[0m"), | ||
bold: init("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"), | ||
dim: init("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"), | ||
italic: init("\x1B[3m", "\x1B[23m"), | ||
underline: init("\x1B[4m", "\x1B[24m"), | ||
inverse: init("\x1B[7m", "\x1B[27m"), | ||
hidden: init("\x1B[8m", "\x1B[28m"), | ||
strikethrough: init("\x1B[9m", "\x1B[29m"), | ||
black: init("\x1B[30m", "\x1B[39m"), | ||
red: init("\x1B[31m", "\x1B[39m"), | ||
green: init("\x1B[32m", "\x1B[39m"), | ||
yellow: init("\x1B[33m", "\x1B[39m"), | ||
blue: init("\x1B[34m", "\x1B[39m"), | ||
magenta: init("\x1B[35m", "\x1B[39m"), | ||
cyan: init("\x1B[36m", "\x1B[39m"), | ||
white: init("\x1B[37m", "\x1B[39m"), | ||
gray: init("\x1B[90m", "\x1B[39m"), | ||
bgBlack: init("\x1B[40m", "\x1B[49m"), | ||
bgRed: init("\x1B[41m", "\x1B[49m"), | ||
bgGreen: init("\x1B[42m", "\x1B[49m"), | ||
bgYellow: init("\x1B[43m", "\x1B[49m"), | ||
bgBlue: init("\x1B[44m", "\x1B[49m"), | ||
bgMagenta: init("\x1B[45m", "\x1B[49m"), | ||
bgCyan: init("\x1B[46m", "\x1B[49m"), | ||
bgWhite: init("\x1B[47m", "\x1B[49m"), | ||
blackBright: init("\x1B[90m", "\x1B[39m"), | ||
redBright: init("\x1B[91m", "\x1B[39m"), | ||
greenBright: init("\x1B[92m", "\x1B[39m"), | ||
yellowBright: init("\x1B[93m", "\x1B[39m"), | ||
blueBright: init("\x1B[94m", "\x1B[39m"), | ||
magentaBright: init("\x1B[95m", "\x1B[39m"), | ||
cyanBright: init("\x1B[96m", "\x1B[39m"), | ||
whiteBright: init("\x1B[97m", "\x1B[39m"), | ||
bgBlackBright: init("\x1B[100m", "\x1B[49m"), | ||
bgRedBright: init("\x1B[101m", "\x1B[49m"), | ||
bgGreenBright: init("\x1B[102m", "\x1B[49m"), | ||
bgYellowBright: init("\x1B[103m", "\x1B[49m"), | ||
bgBlueBright: init("\x1B[104m", "\x1B[49m"), | ||
bgMagentaBright: init("\x1B[105m", "\x1B[49m"), | ||
bgCyanBright: init("\x1B[106m", "\x1B[49m"), | ||
bgWhiteBright: init("\x1B[107m", "\x1B[49m") | ||
reset: f("\x1B[0m", "\x1B[0m"), | ||
bold: f("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"), | ||
dim: f("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"), | ||
italic: f("\x1B[3m", "\x1B[23m"), | ||
underline: f("\x1B[4m", "\x1B[24m"), | ||
inverse: f("\x1B[7m", "\x1B[27m"), | ||
hidden: f("\x1B[8m", "\x1B[28m"), | ||
strikethrough: f("\x1B[9m", "\x1B[29m"), | ||
black: f("\x1B[30m", "\x1B[39m"), | ||
red: f("\x1B[31m", "\x1B[39m"), | ||
green: f("\x1B[32m", "\x1B[39m"), | ||
yellow: f("\x1B[33m", "\x1B[39m"), | ||
blue: f("\x1B[34m", "\x1B[39m"), | ||
magenta: f("\x1B[35m", "\x1B[39m"), | ||
cyan: f("\x1B[36m", "\x1B[39m"), | ||
white: f("\x1B[37m", "\x1B[39m"), | ||
gray: f("\x1B[90m", "\x1B[39m"), | ||
bgBlack: f("\x1B[40m", "\x1B[49m"), | ||
bgRed: f("\x1B[41m", "\x1B[49m"), | ||
bgGreen: f("\x1B[42m", "\x1B[49m"), | ||
bgYellow: f("\x1B[43m", "\x1B[49m"), | ||
bgBlue: f("\x1B[44m", "\x1B[49m"), | ||
bgMagenta: f("\x1B[45m", "\x1B[49m"), | ||
bgCyan: f("\x1B[46m", "\x1B[49m"), | ||
bgWhite: f("\x1B[47m", "\x1B[49m"), | ||
blackBright: f("\x1B[90m", "\x1B[39m"), | ||
redBright: f("\x1B[91m", "\x1B[39m"), | ||
greenBright: f("\x1B[92m", "\x1B[39m"), | ||
yellowBright: f("\x1B[93m", "\x1B[39m"), | ||
blueBright: f("\x1B[94m", "\x1B[39m"), | ||
magentaBright: f("\x1B[95m", "\x1B[39m"), | ||
cyanBright: f("\x1B[96m", "\x1B[39m"), | ||
whiteBright: f("\x1B[97m", "\x1B[39m"), | ||
bgBlackBright: f("\x1B[100m", "\x1B[49m"), | ||
bgRedBright: f("\x1B[101m", "\x1B[49m"), | ||
bgGreenBright: f("\x1B[102m", "\x1B[49m"), | ||
bgYellowBright: f("\x1B[103m", "\x1B[49m"), | ||
bgBlueBright: f("\x1B[104m", "\x1B[49m"), | ||
bgMagentaBright: f("\x1B[105m", "\x1B[49m"), | ||
bgCyanBright: f("\x1B[106m", "\x1B[49m"), | ||
bgWhiteBright: f("\x1B[107m", "\x1B[49m") | ||
}; | ||
@@ -1073,4 +1072,4 @@ }; | ||
var import_node_process4 = __toESM(require("process")); | ||
var import_fast_glob = __toESM(require("fast-glob")); | ||
var import_js_yaml = __toESM(require("js-yaml")); | ||
var import_tinyglobby = require("tinyglobby"); | ||
async function normalizeOptions(raw) { | ||
@@ -1127,3 +1126,3 @@ var _a, _b, _d; | ||
} | ||
const files = await (0, import_fast_glob.default)( | ||
const files = await (0, import_tinyglobby.glob)( | ||
raw.files, | ||
@@ -1133,2 +1132,3 @@ { | ||
onlyFiles: true, | ||
expandDirectories: false, | ||
ignore: [ | ||
@@ -1351,5 +1351,9 @@ "**/{.git,node_modules,bower_components,__tests__,fixtures,fixture}/**" | ||
if (operation.options.execute) { | ||
console.log(log_symbols_default.info, "Executing script", operation.options.execute); | ||
await ezSpawn4.async(operation.options.execute, { stdio: "inherit" }); | ||
console.log(log_symbols_default.success, "Script finished"); | ||
if (typeof operation.options.execute === "function") { | ||
await operation.options.execute(operation); | ||
} else { | ||
console.log(log_symbols_default.info, "Executing script", operation.options.execute); | ||
await ezSpawn4.async(operation.options.execute, { stdio: "inherit" }); | ||
console.log(log_symbols_default.success, "Script finished"); | ||
} | ||
} | ||
@@ -1371,3 +1375,3 @@ await runNpmScript("version" /* Version */, operation); | ||
if (operation.options.execute) | ||
console.log(` execute ${import_picocolors3.default.bold(operation.options.execute)}`); | ||
console.log(` execute ${import_picocolors3.default.bold(typeof operation.options.execute === "function" ? "function" : operation.options.execute)}`); | ||
if (operation.options.push) | ||
@@ -1374,0 +1378,0 @@ console.log(` push ${import_picocolors3.default.cyan(import_picocolors3.default.bold("yes"))}`); |
{ | ||
"name": "bumpp", | ||
"version": "9.7.1", | ||
"packageManager": "pnpm@9.12.1", | ||
"version": "9.8.0", | ||
"packageManager": "pnpm@9.12.3", | ||
"description": "Bump version, commit changes, tag, and push to Git", | ||
@@ -67,24 +67,24 @@ "author": { | ||
"escalade": "^3.2.0", | ||
"fast-glob": "^3.3.2", | ||
"js-yaml": "^4.1.0", | ||
"jsonc-parser": "^3.3.1", | ||
"prompts": "^2.4.2", | ||
"semver": "^7.6.3" | ||
"semver": "^7.6.3", | ||
"tinyglobby": "^0.2.10" | ||
}, | ||
"devDependencies": { | ||
"@antfu/eslint-config": "^3.7.3", | ||
"@antfu/eslint-config": "^3.8.0", | ||
"@types/js-yaml": "^4.0.9", | ||
"@types/node": "^22.7.5", | ||
"@types/node": "^22.8.1", | ||
"@types/prompts": "^2.4.9", | ||
"@types/semver": "^7.5.8", | ||
"eslint": "^9.12.0", | ||
"eslint": "^9.13.0", | ||
"esno": "^4.8.0", | ||
"log-symbols": "^6.0.0", | ||
"npm-check": "^6.0.1", | ||
"picocolors": "^1.1.0", | ||
"picocolors": "^1.1.1", | ||
"rimraf": "^6.0.1", | ||
"tsup": "^8.3.0", | ||
"tsup": "^8.3.5", | ||
"typescript": "^5.6.3", | ||
"vitest": "^2.1.2" | ||
"vitest": "^2.1.4" | ||
} | ||
} |
@@ -11,3 +11,3 @@ # bumpp | ||
- Ships ESM and CJS bundles. | ||
- Add a new argument `--execute` to execute the command before committing. | ||
- Add a new argument `--execute` to execute the command, or execute a function before committing. | ||
- Use the current version's `preid` when available. | ||
@@ -27,3 +27,6 @@ - Confirmation before bumping. | ||
// ...options | ||
execute(config) { | ||
// ...`execute` could receive a function here | ||
} | ||
}) | ||
``` |
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
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
187109
4912
31
11
+ Addedtinyglobby@^0.2.10
+ Addedfdir@6.4.2(transitive)
+ Addedpicomatch@4.0.2(transitive)
+ Addedtinyglobby@0.2.10(transitive)
- Removedfast-glob@^3.3.2
- Removed@nodelib/fs.scandir@2.1.5(transitive)
- Removed@nodelib/fs.stat@2.0.5(transitive)
- Removed@nodelib/fs.walk@1.2.8(transitive)
- Removedfast-glob@3.3.2(transitive)
- Removedfastq@1.17.1(transitive)
- Removedmerge2@1.4.1(transitive)
- Removedmicromatch@4.0.8(transitive)
- Removedqueue-microtask@1.2.3(transitive)
- Removedreusify@1.0.4(transitive)
- Removedrun-parallel@1.2.0(transitive)