Skip to content

Commit

Permalink
bump commander to 12.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
JLHwung committed May 19, 2024
1 parent 15960f7 commit ce44e50
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 11 deletions.
2 changes: 1 addition & 1 deletion packages/babel-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
],
"dependencies": {
"@jridgewell/trace-mapping": "^0.3.25",
"commander": "^6.2.0",
"commander": "condition:BABEL_8_BREAKING ? ^12.0.0 : ^6.2.0",
"convert-source-map": "^2.0.0",
"fs-readdir-recursive": "^1.1.0",
"glob": "condition:BABEL_8_BREAKING ? ^10.3.12 : ^7.2.0 (esm:sync|default)",
Expand Down
1 change: 1 addition & 0 deletions packages/babel-cli/src/babel-external-helpers.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import * as commander from "commander";
import { buildExternalHelpers } from "@babel/core";

// @ts-expect-error TS2339: Property 'default' does not exist on type 'typeof import("./node_modules/commander-BABEL_8_BREAKING-true/typings/index")'
const program = commander.default.program as commander.Command;

function collect(value: unknown, previousValue: Array<string>): Array<string> {
Expand Down
1 change: 1 addition & 0 deletions packages/babel-cli/src/babel/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { alphasort } from "./util.ts";

import type { InputOptions } from "@babel/core";

// @ts-expect-error TS2339: Property 'default' does not exist on type 'typeof import("./node_modules/commander-BABEL_8_BREAKING-true/typings/index")'
const program = commander.default.program as commander.Command;

// Standard Babel input configs.
Expand Down
2 changes: 1 addition & 1 deletion packages/babel-node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
],
"dependencies": {
"@babel/register": "workspace:^",
"commander": "^6.2.0",
"commander": "condition:BABEL_8_BREAKING ? ^12.0.0 : ^6.2.0",
"core-js": "^3.30.2",
"node-environment-flags": "condition:BABEL_8_BREAKING ? : ^1.0.5",
"regenerator-runtime": "^0.14.0",
Expand Down
1 change: 1 addition & 0 deletions packages/babel-node/src/_babel-node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import type { PluginAPI, PluginObject } from "@babel/core";

const require = createRequire(import.meta.url);

// @ts-expect-error TS2339: Property 'default' does not exist on type 'typeof import("./node_modules/commander-BABEL_8_BREAKING-true/typings/index")'
const program = commander.default.program as commander.Command;

function collect(value: unknown, previousValue: string[]): Array<string> {
Expand Down
1 change: 1 addition & 0 deletions scripts/generators/tsconfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,7 @@ fs.writeFileSync(
"babel-plugin-dynamic-import-node/utils",
["./lib/babel-plugin-dynamic-import-node.d.ts"],
],
["commander", ["./node_modules/commander-BABEL_8_BREAKING-true"]],
["glob", ["./node_modules/glob-BABEL_8_BREAKING-true"]],
["globals", ["./node_modules/globals-BABEL_8_BREAKING-true"]],
["js-tokens", ["./node_modules/js-tokens-BABEL_8_BREAKING-true"]],
Expand Down
3 changes: 3 additions & 0 deletions tsconfig.paths.json
Original file line number Diff line number Diff line change
Expand Up @@ -602,6 +602,9 @@
"babel-plugin-dynamic-import-node/utils": [
"./lib/babel-plugin-dynamic-import-node.d.ts"
],
"commander": [
"./node_modules/commander-BABEL_8_BREAKING-true"
],
"glob": [
"./node_modules/glob-BABEL_8_BREAKING-true"
],
Expand Down
35 changes: 26 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ __metadata:
"@types/fs-readdir-recursive": "npm:^1.1.0"
"@types/glob": "npm:^7.2.0"
chokidar: "npm:^3.4.0"
commander: "npm:^6.2.0"
commander: "condition:BABEL_8_BREAKING ? ^12.0.0 : ^6.2.0"
convert-source-map: "npm:^2.0.0"
fs-readdir-recursive: "npm:^1.1.0"
glob: "condition:BABEL_8_BREAKING ? ^10.3.12 : ^7.2.0 (esm:sync|default)"
Expand Down Expand Up @@ -1256,7 +1256,7 @@ __metadata:
"@babel/register": "workspace:^"
"@babel/runtime": "workspace:^"
"@types/v8flags": "npm:^3.1.1"
commander: "npm:^6.2.0"
commander: "condition:BABEL_8_BREAKING ? ^12.0.0 : ^6.2.0"
core-js: "npm:^3.30.2"
node-environment-flags: "condition:BABEL_8_BREAKING ? : ^1.0.5"
regenerator-runtime: "npm:^0.14.0"
Expand Down Expand Up @@ -8116,6 +8116,30 @@ __metadata:
languageName: node
linkType: hard

"commander-BABEL_8_BREAKING-false@npm:commander@^6.2.0":
version: 6.2.1
resolution: "commander@npm:6.2.1"
checksum: 10/25b88c2efd0380c84f7844b39cf18510da7bfc5013692d68cdc65f764a1c34e6c8a36ea6d72b6620e3710a930cf8fab2695bdec2bf7107a0f4fa30a3ef3b7d0e
languageName: node
linkType: hard

"commander-BABEL_8_BREAKING-true@npm:commander@^12.0.0":
version: 12.0.0
resolution: "commander@npm:12.0.0"
checksum: 10/62062e2ffe6abd5aa42a551e62fd5eb9b2620f6ac4299382b2aa9fb02f95cda0242d7e84acb890479bd6491edb805f7f91aecb5b4f5c70dc57df49ed7f02ef14
languageName: node
linkType: hard

"commander@condition:BABEL_8_BREAKING ? ^12.0.0 : ^6.2.0":
version: 0.0.0-condition-3490ed
resolution: "commander@condition:BABEL_8_BREAKING?^12.0.0:^6.2.0#3490ed"
dependencies:
commander-BABEL_8_BREAKING-false: "npm:commander@^6.2.0"
commander-BABEL_8_BREAKING-true: "npm:commander@^12.0.0"
checksum: 10/0f72a1ef05986d7ce60ddc8a7abc5e167858e8c77dc73e3f26e34127bad695f9051f2f2dc45afd01a88275991da05e21999d810474e77f550f96f14411477fba
languageName: node
linkType: hard

"commander@npm:11.1.0":
version: 11.1.0
resolution: "commander@npm:11.1.0"
Expand All @@ -8137,13 +8161,6 @@ __metadata:
languageName: node
linkType: hard

"commander@npm:^6.2.0":
version: 6.2.1
resolution: "commander@npm:6.2.1"
checksum: 10/25b88c2efd0380c84f7844b39cf18510da7bfc5013692d68cdc65f764a1c34e6c8a36ea6d72b6620e3710a930cf8fab2695bdec2bf7107a0f4fa30a3ef3b7d0e
languageName: node
linkType: hard

"commander@npm:^7.0.0":
version: 7.1.0
resolution: "commander@npm:7.1.0"
Expand Down

0 comments on commit ce44e50

Please sign in to comment.