Skip to content

Commit ca44d80

Browse files
escapedcatclaude
andcommitted
fix: update dependency yargs to v18 #4432
- Fix singleton pattern in pkg-check.js (use yargs(process.argv.slice(2))) - Use parseSync() instead of .argv in pkg-check.js - Keep @types/yargs (v18 doesn't ship own types yet) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 9c07126 commit ca44d80

4 files changed

Lines changed: 33 additions & 6 deletions

File tree

@commitlint/cli/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
"@commitlint/read": "^20.5.0",
5555
"@commitlint/types": "^20.5.0",
5656
"tinyexec": "^1.0.0",
57-
"yargs": "^17.0.0"
57+
"yargs": "^18.0.0"
5858
},
5959
"gitHead": "e82f05a737626bb69979d14564f5ff601997f679"
6060
}

@packages/utils/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"tar-fs": "^3.0.5",
5050
"tinyexec": "^1.0.0",
5151
"tmp": "^0.2.1",
52-
"yargs": "^17.0.0"
52+
"yargs": "^18.0.0"
5353
},
5454
"gitHead": "71f0194f33943954a8dac1c458be47e5049717cd"
5555
}

@packages/utils/pkg-check.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ function main(flags) {
9090
}
9191

9292
main(
93-
yargs
93+
yargs(process.argv.slice(2))
9494
.options({
9595
cwd: {
9696
description: "directory to execute in",
@@ -118,7 +118,8 @@ main(
118118
.example("$0", "")
119119
.help()
120120
.version()
121-
.strict().argv,
121+
.strict()
122+
.parseSync(),
122123
)
123124
.then((report) => {
124125
if (report.problems.length > 0) {

yarn.lock

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3112,6 +3112,15 @@ cliui@^8.0.1:
31123112
strip-ansi "^6.0.1"
31133113
wrap-ansi "^7.0.0"
31143114

3115+
cliui@^9.0.1:
3116+
version "9.0.1"
3117+
resolved "https://registry.npmjs.org/cliui/-/cliui-9.0.1.tgz#6f7890f386f6f1f79953adc1f78dec46fcc2d291"
3118+
integrity sha512-k7ndgKhwoQveBL+/1tqGJYNz097I7WOvwbmmU2AR5+magtbjPWQTS1C5vzGkBC8Ym8UWRzfKUzUUqFLypY4Q+w==
3119+
dependencies:
3120+
string-width "^7.2.0"
3121+
strip-ansi "^7.1.0"
3122+
wrap-ansi "^9.0.0"
3123+
31153124
clone-deep@4.0.1:
31163125
version "4.0.1"
31173126
resolved "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz#c19fd9bdbbf85942b4fd979c84dcf7d5f07c2387"
@@ -7109,7 +7118,7 @@ string-width@^5.0.1, string-width@^5.1.2:
71097118
emoji-regex "^9.2.2"
71107119
strip-ansi "^7.0.1"
71117120

7112-
string-width@^7.0.0:
7121+
string-width@^7.0.0, string-width@^7.2.0:
71137122
version "7.2.0"
71147123
resolved "https://registry.npmjs.org/string-width/-/string-width-7.2.0.tgz#b5bb8e2165ce275d4d43476dd2700ad9091db6dc"
71157124
integrity sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==
@@ -7969,7 +7978,12 @@ yargs-parser@^20.2.2, yargs-parser@^20.2.3:
79697978
resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee"
79707979
integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==
79717980

7972-
yargs@17.7.2, yargs@^17.0.0, yargs@^17.6.2:
7981+
yargs-parser@^22.0.0:
7982+
version "22.0.0"
7983+
resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-22.0.0.tgz#87b82094051b0567717346ecd00fd14804b357c8"
7984+
integrity sha512-rwu/ClNdSMpkSrUb+d6BRsSkLUq1fmfsY6TOpYzTwvwkg1/NRG85KBy3kq++A8LKQwX6lsu+aWad+2khvuXrqw==
7985+
7986+
yargs@17.7.2, yargs@^17.6.2:
79737987
version "17.7.2"
79747988
resolved "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269"
79757989
integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==
@@ -7995,6 +8009,18 @@ yargs@^16.2.0:
79958009
y18n "^5.0.5"
79968010
yargs-parser "^20.2.2"
79978011

8012+
yargs@^18.0.0:
8013+
version "18.0.0"
8014+
resolved "https://registry.npmjs.org/yargs/-/yargs-18.0.0.tgz#6c84259806273a746b09f579087b68a3c2d25bd1"
8015+
integrity sha512-4UEqdc2RYGHZc7Doyqkrqiln3p9X2DZVxaGbwhn2pi7MrRagKaOcIKe8L3OxYcbhXLgLFUS3zAYuQjKBQgmuNg==
8016+
dependencies:
8017+
cliui "^9.0.1"
8018+
escalade "^3.1.1"
8019+
get-caller-file "^2.0.5"
8020+
string-width "^7.2.0"
8021+
y18n "^5.0.5"
8022+
yargs-parser "^22.0.0"
8023+
79988024
yocto-queue@^0.1.0:
79998025
version "0.1.0"
80008026
resolved "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b"

0 commit comments

Comments
 (0)