From afad3532a0caac714c6e6f464058393743b2f801 Mon Sep 17 00:00:00 2001 From: MK Date: Sun, 20 Sep 2026 01:18:07 +0800 Subject: [PATCH] fix(staged)!: upgrade lint-staged and automate future updates BREAKING CHANGE: vp staged now requires Node.js 22.22.1 or later and Git 2.32.0 or later. Node.js 20 is no longer supported for staged checks. The existing Node.js 24.11.0 minimum still applies to the 24.x line. These requirements also apply to pre-commit hooks that run vp staged. --- .../scripts/__tests__/upgrade-deps.spec.ts | 71 +++++++ .github/scripts/upgrade-deps.ts | 11 ++ .../snapshots/command_staged_concurrent.md | 17 +- .../command_staged_no_stash_restore/fail.cjs | 1 + .../command_staged_no_stash_restore/file.txt | 1 + .../package.json | 5 + .../snapshots.toml | 16 ++ .../command_staged_no_stash_restore.global.md | 56 ++++++ .../command_staged_no_stash_restore.local.md | 56 ++++++ .../vite.config.ts | 5 + .../snapshots/command_staged_with_config.md | 40 ++-- .../tests/cli_snapshots/redact.rs | 5 +- crates/vp_cli_snapshots/tests/redact_unit.rs | 18 ++ docs/guide/commit-hooks.md | 9 +- pnpm-lock.yaml | 181 +----------------- pnpm-workspace.yaml | 2 +- 16 files changed, 295 insertions(+), 199 deletions(-) create mode 100644 .github/scripts/__tests__/upgrade-deps.spec.ts create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/fail.cjs create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/file.txt create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/package.json create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots.toml create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.global.md create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.local.md create mode 100644 crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/vite.config.ts diff --git a/.github/scripts/__tests__/upgrade-deps.spec.ts b/.github/scripts/__tests__/upgrade-deps.spec.ts new file mode 100644 index 0000000000..a9cd1a258b --- /dev/null +++ b/.github/scripts/__tests__/upgrade-deps.spec.ts @@ -0,0 +1,71 @@ +/// + +import { copyFileSync, mkdirSync, mkdtempSync, readFileSync, rmSync, writeFileSync } from 'node:fs'; +import { tmpdir } from 'node:os'; +import { dirname, join, resolve } from 'node:path'; + +import { expect, test, vi } from 'vitest'; + +test('upgrades lint-staged across major versions and includes it in upgrade metadata', async ({ + onTestFinished, +}) => { + const root = resolve(import.meta.dirname, '../../..'); + const tempDir = mkdtempSync(join(tmpdir(), 'vite-plus-upgrade-deps-')); + const metaDir = join(tempDir, 'meta'); + onTestFinished(() => { + vi.restoreAllMocks(); + vi.unstubAllGlobals(); + vi.unstubAllEnvs(); + vi.resetModules(); + rmSync(tempDir, { recursive: true, force: true }); + }); + + for (const file of [ + 'pnpm-workspace.yaml', + 'packages/tools/.upstream-versions.json', + 'packages/cli/src/utils/constants.ts', + ]) { + mkdirSync(dirname(join(tempDir, file)), { recursive: true }); + copyFileSync(join(root, file), join(tempDir, file)); + } + const workspacePath = join(tempDir, 'pnpm-workspace.yaml'); + writeFileSync( + workspacePath, + readFileSync(workspacePath, 'utf8').replace(/ lint-staged: .+/, ' lint-staged: ^16.2.6'), + ); + + vi.spyOn(process, 'cwd').mockReturnValue(tempDir); + vi.spyOn(console, 'log').mockImplementation(() => {}); + vi.stubEnv('UPGRADE_DEPS_META_DIR', metaDir); + vi.stubGlobal('fetch', async (url: string) => { + if (url.startsWith('https://api.github.com/repos/')) { + return Response.json([{ name: 'v1.2.3', commit: { sha: 'a'.repeat(40) } }]); + } + if (url === 'https://registry.npmjs.org/vitest') { + return Response.json({ versions: { '4.1.11': {}, '5.0.0': {} } }); + } + if (url === 'https://registry.npmjs.org/@tsdown/css/latest') { + return Response.json({ dependencies: { lightningcss: '^1.33.0' } }); + } + if (url === 'https://registry.npmjs.org/lint-staged/latest') { + return Response.json({ version: '17.5.1' }); + } + if (url.startsWith('https://registry.npmjs.org/') && url.endsWith('/latest')) { + return Response.json({ version: '1.2.3' }); + } + throw new Error(`Unexpected request: ${url}`); + }); + + vi.resetModules(); + await import('../upgrade-deps.ts'); + + expect(readFileSync(workspacePath, 'utf8')).toContain('\n lint-staged: ^17.5.1\n'); + const versions = JSON.parse(readFileSync(join(metaDir, 'versions.json'), 'utf8')); + expect(versions['lint-staged']).toEqual({ old: '16.2.6', new: '17.5.1' }); + expect(readFileSync(join(metaDir, 'commit-message.txt'), 'utf8')).toContain( + '- lint-staged: 16.2.6 -> 17.5.1', + ); + expect(readFileSync(join(metaDir, 'pr-body.md'), 'utf8')).toContain( + '| `lint-staged` | `16.2.6` | `17.5.1` |', + ); +}); diff --git a/.github/scripts/upgrade-deps.ts b/.github/scripts/upgrade-deps.ts index acc5a6e633..feeded4c71 100644 --- a/.github/scripts/upgrade-deps.ts +++ b/.github/scripts/upgrade-deps.ts @@ -50,6 +50,7 @@ type PnpmWorkspaceVersions = { vitest: string; tsdown: string; lightningcss: string; + lintStaged: string; oxcNodeCli: string; oxcNodeCore: string; oxfmt: string; @@ -278,6 +279,12 @@ async function updatePnpmWorkspace(versions: PnpmWorkspaceVersions): Promise) -✔ Running tasks for staged files... -✔ Applying modifications from tasks... -✔ Cleaning up temporary files... +⋯ Backing up original state… +✔ Done backing up original state ()! +⋯ Running tasks for staged files… + *.txt — 1 file + ⋯ vpt print linted + +✔ vpt print linted + +✔ Done running tasks for staged files! +⋯ Staging changes from tasks… +✔ Done staging changes from tasks! +⋯ Cleaning up temporary files… +✔ Done cleaning up temporary files! → vpt print linted: linted /a.txt diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/fail.cjs b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/fail.cjs new file mode 100644 index 0000000000..6cee2e1e79 --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/fail.cjs @@ -0,0 +1 @@ +process.exit(1); diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/file.txt b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/file.txt new file mode 100644 index 0000000000..4b48deed3a --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/file.txt @@ -0,0 +1 @@ +original diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/package.json b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/package.json new file mode 100644 index 0000000000..71a678f6fe --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/package.json @@ -0,0 +1,5 @@ +{ + "name": "command-staged-no-stash-restore", + "private": true, + "type": "module" +} diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots.toml b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots.toml new file mode 100644 index 0000000000..833701b6a6 --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots.toml @@ -0,0 +1,16 @@ +[[case]] +name = "command_staged_no_stash_restore" +vp = ["local", "global"] +comment = "A failed task with --no-stash must restore the unstaged part of a partially staged file." +steps = [ + { argv = ["git", "init"], snapshot = false }, + { argv = ["git", "add", "-A"], snapshot = false }, + { argv = ["git", "-c", "user.name=Vite Plus", "-c", "user.email=vite-plus@example.com", "commit", "-m", "init"], snapshot = false }, + { argv = ["vpt", "write-file", "file.txt", "staged\n"], snapshot = false }, + { argv = ["git", "add", "file.txt"], snapshot = false }, + { argv = ["vpt", "write-file", "file.txt", "staged\nunstaged\n"], snapshot = false }, + { argv = ["vp", "staged", "--no-stash", "--quiet"], continue-on-failure = true }, + { argv = ["vpt", "print-file", "file.txt"], comment = "The working tree retains both staged and unstaged changes.", continue-on-failure = true }, + { argv = ["git", "show", ":file.txt"], comment = "The index retains only the staged change." }, + { argv = ["git", "stash", "list"], comment = "No backup stash is created." }, +] diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.global.md b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.global.md new file mode 100644 index 0000000000..3c19ba8675 --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.global.md @@ -0,0 +1,56 @@ +# command_staged_no_stash_restore + +A failed task with --no-stash must restore the unstaged part of a partially staged file. + +## `git init` + + +## `git add -A` + + +## `git -c 'user.name=Vite Plus' -c user.email=vite-plus@example.com commit -m init` + + +## `vpt write-file file.txt 'staged +'` + + +## `git add file.txt` + + +## `vpt write-file file.txt 'staged +unstaged +'` + + +## `vp staged --no-stash --quiet` + +**Exit code:** 1 + +``` +✖ node fail.cjs +``` + +## `vpt print-file file.txt` + +The working tree retains both staged and unstaged changes. + +``` +staged +unstaged +``` + +## `git show :file.txt` + +The index retains only the staged change. + +``` +staged +``` + +## `git stash list` + +No backup stash is created. + +``` +``` diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.local.md b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.local.md new file mode 100644 index 0000000000..3c19ba8675 --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/snapshots/command_staged_no_stash_restore.local.md @@ -0,0 +1,56 @@ +# command_staged_no_stash_restore + +A failed task with --no-stash must restore the unstaged part of a partially staged file. + +## `git init` + + +## `git add -A` + + +## `git -c 'user.name=Vite Plus' -c user.email=vite-plus@example.com commit -m init` + + +## `vpt write-file file.txt 'staged +'` + + +## `git add file.txt` + + +## `vpt write-file file.txt 'staged +unstaged +'` + + +## `vp staged --no-stash --quiet` + +**Exit code:** 1 + +``` +✖ node fail.cjs +``` + +## `vpt print-file file.txt` + +The working tree retains both staged and unstaged changes. + +``` +staged +unstaged +``` + +## `git show :file.txt` + +The index retains only the staged change. + +``` +staged +``` + +## `git stash list` + +No backup stash is created. + +``` +``` diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/vite.config.ts b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/vite.config.ts new file mode 100644 index 0000000000..cf48a2c048 --- /dev/null +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_no_stash_restore/vite.config.ts @@ -0,0 +1,5 @@ +export default { + staged: { + '*.txt': 'node fail.cjs', + }, +}; diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_with_config/snapshots/command_staged_with_config.md b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_with_config/snapshots/command_staged_with_config.md index 93d3225ae5..f43d6670d4 100644 --- a/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_with_config/snapshots/command_staged_with_config.md +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/fixtures/command_staged_with_config/snapshots/command_staged_with_config.md @@ -24,10 +24,19 @@ append foo (write-file with the full appended content) should succeed with staged .ts files ``` -✔ Backed up original state in git stash () -✔ Running tasks for staged files... -✔ Applying modifications from tasks... -✔ Cleaning up temporary files... +⋯ Backing up original state… +✔ Done backing up original state ()! +⋯ Running tasks for staged files… + *.ts — 1 file + ⋯ vp check --fix + +✔ vp check --fix + +✔ Done running tasks for staged files! +⋯ Staging changes from tasks… +✔ Done staging changes from tasks! +⋯ Cleaning up temporary files… +✔ Done cleaning up temporary files! ``` ## `git add -A` @@ -72,15 +81,20 @@ should fail when staged .js file has lint errors **Exit code:** 1 ``` -✔ Backed up original state in git stash () -⚠ Running tasks for staged files... - ❯ Config object — 1 file - ↓ *.ts — no files - ❯ *.js — 1 file - ✖ vp lint [FAILED] -↓ Skipped because of errors from tasks. -✔ Reverting to original state because of errors... -✔ Cleaning up temporary files... +⋯ Backing up original state… +✔ Done backing up original state ()! +⋯ Running tasks for staged files… + *.js — 1 file + ⋯ vp lint + +✖ vp lint + +✖ Failed to run tasks for staged files! +↓ Skipped staging changes from tasks… +⋯ Reverting to original state because of errors… +✔ Done reverting to original state! +⋯ Cleaning up temporary files… +✔ Done cleaning up temporary files! ✖ vp lint: diff --git a/crates/vp_cli_snapshots/tests/cli_snapshots/redact.rs b/crates/vp_cli_snapshots/tests/cli_snapshots/redact.rs index 5cc9576271..cff1c8f647 100644 --- a/crates/vp_cli_snapshots/tests/cli_snapshots/redact.rs +++ b/crates/vp_cli_snapshots/tests/cli_snapshots/redact.rs @@ -278,8 +278,9 @@ static YARN_TELEMETRY_RE: LazyLock = LazyLock::new(|| regex::Regex::new(r"(?m)^\u{27A4} YN0065: [^\n]*\n(?:[ \t]*\n)*").unwrap()); // `vp staged` reports the backup stash it created; the short hash covers a // commit of the working tree at run time, so it can never be stable. -static STASH_HASH_RE: LazyLock = - LazyLock::new(|| regex::Regex::new(r"(git stash \()[0-9a-f]+(\))").unwrap()); +static STASH_HASH_RE: LazyLock = LazyLock::new(|| { + regex::Regex::new(r"((?:git stash|Done backing up original state) \()[0-9a-f]+(\))").unwrap() +}); // Package managers emit blank separator lines whose count races their own // progress rendering under a PTY; collapse runs so spacing is stable. static BLANK_RUN_RE: LazyLock = diff --git a/crates/vp_cli_snapshots/tests/redact_unit.rs b/crates/vp_cli_snapshots/tests/redact_unit.rs index 71a80ff3ad..3d63124d11 100644 --- a/crates/vp_cli_snapshots/tests/redact_unit.rs +++ b/crates/vp_cli_snapshots/tests/redact_unit.rs @@ -87,6 +87,24 @@ fn masks_bun_build_hash_only_in_bun_banners() { assert_eq!(redact_output(unrelated.clone(), &[], true), unrelated); } +#[test] +fn masks_lint_staged_backup_hashes() { + let input = concat!( + "✔ Backed up original state in git stash (a1b2c3d)\n", + "✔ Done backing up original state (d4e5f6a)!\n", + "commit (deadbeef1) applied\n", + ) + .to_owned(); + assert_eq!( + redact_output(input, &[], true), + concat!( + "✔ Backed up original state in git stash ()\n", + "✔ Done backing up original state ()!\n", + "commit (deadbeef1) applied\n", + ) + ); +} + #[test] fn normalizes_managed_executable_paths_and_missing_commands() { let input = concat!( diff --git a/docs/guide/commit-hooks.md b/docs/guide/commit-hooks.md index 96a5480bc2..6b3fe4be6e 100644 --- a/docs/guide/commit-hooks.md +++ b/docs/guide/commit-hooks.md @@ -80,7 +80,14 @@ Project-owned hook scripts such as `.vite-hooks/pre-commit` should be committed ### `vp staged` -`vp staged` runs staged-file checks using the `staged` config from `vite.config.ts`. To run it before each commit, add it to the project-owned pre-commit hook: +`vp staged` runs staged-file checks using the `staged` config from `vite.config.ts`. It bundles `lint-staged` 17 and requires: + +- Node.js `22.22.1` or later in the `22.x` line, or `24.11.0` or later +- Git `2.32.0` or later + +Node.js `20.x` is no longer supported for staged checks. These requirements also apply when a pre-commit hook runs `vp staged`. Upgrade the project's Node.js runtime and the Git installation on developer machines and CI runners before using the command. See the [lint-staged 17 release notes](https://github.com/lint-staged/lint-staged/releases/tag/v17.0.0) for the upstream changes. + +To run it before each commit, add it to the project-owned pre-commit hook: ```bash vp staged diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 17a7772290..f6bfc1ab5c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -172,8 +172,8 @@ catalogs: specifier: ^1.33.0 version: 1.33.0 lint-staged: - specifier: ^16.2.6 - version: 16.4.0 + specifier: ^17.5.1 + version: 17.5.1 lodash-es: specifier: ^4.17.21 version: 4.17.23 @@ -425,7 +425,7 @@ importers: version: 3.3.1 lint-staged: specifier: 'catalog:' - version: 16.4.0 + version: 17.5.1 minimatch: specifier: 'catalog:' version: 10.2.4 @@ -5258,10 +5258,6 @@ packages: resolution: {integrity: sha512-Ab9UQDstwhrTcsRP1m4QkT6W1PRMBoAnPJeB5LZcuum/nLiFMlSwYxH1J8fsRAolaXez0ijgbm6BAWZkQC9DVg==} engines: {node: '>=18.3.0'} - ansi-escapes@7.2.0: - resolution: {integrity: sha512-g6LhBsl+GBPRWGWsBtutpzBYuIIdBkLEvad5C/va/74Db018+5TZiyA26cZJAr3Rft5lprVqOIPxf5Vid6tqAw==} - engines: {node: '>=18'} - ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} @@ -5563,14 +5559,6 @@ packages: cjs-module-lexer@2.1.1: resolution: {integrity: sha512-+CmxIZ/L2vNcEfvNtLdU0ZQ6mbq3FZnwAP2PPTiKP+1QOoKwlKlPgb8UKV0Dds7QVaMnHm+FwSft2VB0s/SLjQ==} - cli-cursor@5.0.0: - resolution: {integrity: sha512-aCj4O5wKyszjMmDT4tZj93kxyydN/K5zPWSCe6/0AV/AA1pqe5ZBIw0a2ZfPQV7lL5/yb5HsUreJ6UFAF1tEQw==} - engines: {node: '>=18'} - - cli-truncate@5.2.0: - resolution: {integrity: sha512-xRwvIOMGrfOAnM1JYtqQImuaNtDEv9v6oIYAs4LIHwTiKee8uwvIi363igssOC0O5U04i4AlENs79LQLu9tEMw==} - engines: {node: '>=20'} - cli-width@4.1.0: resolution: {integrity: sha512-ouuZd4/dm2Sw5Gmqy6bGyNNNe1qt9RpmxveLSO7KcgsTnU7RXfsw+/bukWGo1abgBiMAic068rclZsO4IWmmxQ==} engines: {node: '>= 12'} @@ -5597,10 +5585,6 @@ packages: colorjs.io@0.7.1: resolution: {integrity: sha512-LY7OHnJZxHwT5UlzNa9bbhHHDbzB6yE5+3MIPwJEQKRvSCt/T4G7epsj+9j2BExUIIfXFIJGsIXUKdfrK9Q5tA==} - commander@14.0.3: - resolution: {integrity: sha512-H+y0Jo/T1RZ9qPP4Eh1pkcQcLRglraJaSLoyOtHxu6AapkjWVCy2Sit1QQ4x3Dng8qDlSsZEet7g5Pq06MvTgw==} - engines: {node: '>=20'} - commander@2.20.3: resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} @@ -5904,9 +5888,6 @@ packages: node-addon-api: optional: true - emoji-regex@10.6.0: - resolution: {integrity: sha512-toUI84YS5YmxW219erniWD0CIVOo46xGKColeNQRgOzDorgBi1v4D71/OFzgD9GO2UGKIv1C3Sp8DAn0+j5w7A==} - emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} @@ -5951,10 +5932,6 @@ packages: resolution: {integrity: sha512-zwfzJecQ/Uej6tusMqwAqU/6KL2XaB2VZ2Jg54Je6ahNBGNH6Ek6g3jjNCF0fG9EWQKGZNddNjU5F1ZQn/sBnA==} engines: {node: '>=20.19.0'} - environment@1.1.0: - resolution: {integrity: sha512-xUtoPkMggbz0MPyPiIWr1Kp4aeWJjDZ6SMvURhimjdZgsRuDplF5/s9hcgGhyXMhs+6vpnuoiZ2kFiu3FMnS8Q==} - engines: {node: '>=18'} - errno@0.1.8: resolution: {integrity: sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A==} hasBin: true @@ -6117,9 +6094,6 @@ packages: resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} engines: {node: '>=6'} - eventemitter3@5.0.4: - resolution: {integrity: sha512-mlsTRyGaPBjPedk6Bvw+aqbsXDtoAyAzm5MO7JgU+yVRyMQ5O8bD4Kcci7BS85f93veegeCPkL8R4GLClnjLFw==} - events-universal@1.0.1: resolution: {integrity: sha512-LUd5euvbMLpwOF8m6ivPCbhQeSiYVNb8Vs0fQ8QjXo0JTkEHpz8pxdQf0gStltaPpw0Cca8b39KxvK9cfKRiAw==} @@ -6292,10 +6266,6 @@ packages: resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} engines: {node: 6.* || 8.* || >= 10.*} - get-east-asian-width@1.6.0: - resolution: {integrity: sha512-QRbvDIbx6YklUe6RxeTeleMR0yv3cYH6PsPZHcnVn7xv7zO1BHN8r0XETu8n6Ye3Q+ahtSarc3WgtNWmehIBfA==} - engines: {node: '>=18'} - get-github-auth-token@0.1.2: resolution: {integrity: sha512-vcGCRhKNOOynlxi7j3dOrkCkxG1rxt/IbmZY9A+xXMhRAUMeIA5T4Fn0LTaPXfQWdUkOcc3DBWDvcc6dmnxmYw==} engines: {node: '>=18'} @@ -6527,10 +6497,6 @@ packages: resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} engines: {node: '>=8'} - is-fullwidth-code-point@5.1.0: - resolution: {integrity: sha512-5XHYaSyiqADb4RnZ1Bdad6cPp8Toise4TzEjcOYDHZkTCbKgiUl7WTUCpNWHuxmDt91wnsZBc9xinNzopv3JMQ==} - engines: {node: '>=18'} - is-glob@4.0.3: resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} engines: {node: '>=0.10.0'} @@ -6774,20 +6740,11 @@ packages: resolution: {integrity: sha512-/vlFKAoH5Cgt3Ie+JLhRbwOsCQePABiU3tJ1egGvyQ+33R/vcwM2Zl2QR/LzjsBeItPt3oSVXapn+m4nQDvpzw==} engines: {node: '>=14'} - lint-staged@16.4.0: - resolution: {integrity: sha512-lBWt8hujh/Cjysw5GYVmZpFHXDCgZzhrOm8vbcUdobADZNOK/bRshr2kM3DfgrrtR1DQhfupW9gnIXOfiFi+bw==} - engines: {node: '>=20.17'} - hasBin: true - lint-staged@17.5.1: resolution: {integrity: sha512-7EDuco1xnBMeVpvAbeMq1U5KXwJGLmY8q6l+Ye78r36C4mPc+Vg1Z2SK8gHyRTyvPro90A0q5/FAZ+Au23d6QQ==} engines: {node: '>=22.22.1'} hasBin: true - listr2@9.0.5: - resolution: {integrity: sha512-ME4Fb83LgEgwNw96RKNvKV4VTLuXfoKudAmm2lP8Kk87KaMK0/Xrx/aAkMWmT8mDb+3MlFDspfbCs7adjRxA2g==} - engines: {node: '>=20.0.0'} - loader-utils@3.3.1: resolution: {integrity: sha512-FMJTLMXfCLMLfJxcX9PFqX5qD88Z5MRGaZCVzfuqeZSPsyiBzs+pahDQjbIWz2QIzPZz0NX9Zy4FX3lmK6YHIg==} engines: {node: '>= 12.13.0'} @@ -6824,10 +6781,6 @@ packages: lodash@4.17.21: resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} - log-update@6.1.0: - resolution: {integrity: sha512-9ie8ItPR6tjY5uYJh8K/Zrv/RMZ5VOlOWvtZdEHYSTFKZfIBPQa9tOAEeAWhd+AnIneLJ22w5fjOYtoutpWq5w==} - engines: {node: '>=18'} - loglevel-plugin-prefix@0.8.4: resolution: {integrity: sha512-WpG9CcFAOjz/FtNht+QJeGpvVl/cdR6P0z6OcXSkr8wFJOsV2GRj2j10JLfjuA4aYkcKCNIEqRGCyTife9R8/g==} @@ -6891,10 +6844,6 @@ packages: engines: {node: '>=4'} hasBin: true - mimic-function@5.0.1: - resolution: {integrity: sha512-VP79XUPxV2CigYP3jWwAUFSku2aKqBH7uTAapFWCBqutsbmDo96KY5o8uh6U+/YSIn5OxJnXp73beVkpqMIGhA==} - engines: {node: '>=18'} - minimatch@10.2.4: resolution: {integrity: sha512-oRjTw/97aTBN0RHbYCdtF1MQfvusSIBQM0IZEgzl6426+8jSC0nF1a/GmnVLpfB9yyr6g6FTqWqiZVbxrtaCIg==} engines: {node: 18 || 20 || >=22} @@ -7059,10 +7008,6 @@ packages: once@1.4.0: resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} - onetime@7.0.0: - resolution: {integrity: sha512-VXJjc87FScF88uafS3JllDgvAm+c/Slfz06lorj2uAY34rlUu0Nt+v8wreiImcrgAjjIHp1rXpTDlLOGw29WwQ==} - engines: {node: '>=18'} - open@10.2.0: resolution: {integrity: sha512-YgBpdJHPyQ2UE5x+hlSXcnejzAvD0b22U2OuAP+8OnlJT+PjWPxtgmGqKKc+RgTM63U9gN0YzrYc71R2WT/hTA==} engines: {node: '>=18'} @@ -7525,17 +7470,10 @@ packages: resq@1.11.0: resolution: {integrity: sha512-G10EBz+zAAy3zUd/CDoBbXRL6ia9kOo3xRHrMDsHljI0GDkhYlyjwoCx5+3eCC4swi1uCoZQhskuJkj7Gp57Bw==} - restore-cursor@5.1.0: - resolution: {integrity: sha512-oMA2dcrw6u0YfxJQXm342bFKX/E4sG9rbTzO9ptUcR/e8A33cHuvStiYOwH7fszkZlZ1z/ta9AAoPk2F4qIOHA==} - engines: {node: '>=18'} - ret@0.5.0: resolution: {integrity: sha512-I1XxrZSQ+oErkRR4jYbAyEEu2I0avBvvMM5JN+6EBprOGRCs63ENqZ3vjavq8fBw2+62G5LF5XelKwuJpcvcxw==} engines: {node: '>=10'} - rfdc@1.4.1: - resolution: {integrity: sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==} - rgb2hex@0.2.5: resolution: {integrity: sha512-22MOP1Rh7sAo1BZpDG6R5RFYzR2lYEgwq7HEmyW2qcsOqR2lQKmn+O//xV3YG/0rrhMC6KVX2hU+ZXuaw9a5bw==} @@ -7842,14 +7780,6 @@ packages: sisteransi@1.0.5: resolution: {integrity: sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==} - slice-ansi@7.1.2: - resolution: {integrity: sha512-iOBWFgUX7caIZiuutICxVgX1SdxwAVFFKwt1EvMYYec/NWO5meOJ6K5uQxhrYBdQJne4KxiqZc+KptFOWFSI9w==} - engines: {node: '>=18'} - - slice-ansi@8.0.0: - resolution: {integrity: sha512-stxByr12oeeOyY2BlviTNQlYV5xOj47GirPr4yA1hE9JCtxfQN0+tVbkxwCtYDQWhEKWFHsEK48ORg5jrouCAg==} - engines: {node: '>=20'} - slugify@1.6.6: resolution: {integrity: sha512-h+z7HKHYXj6wJU+AnS/+IH8Uh9fdcX1Lrhg1/VMdf9PwoBQXFcXiAdsy2tSK0P6gKwJLXp02r90ahUCqHk9rrw==} engines: {node: '>=8.0.0'} @@ -7965,14 +7895,6 @@ packages: resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} engines: {node: '>=12'} - string-width@7.2.0: - resolution: {integrity: sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==} - engines: {node: '>=18'} - - string-width@8.2.1: - resolution: {integrity: sha512-IIaP0g3iy9Cyy18w3M9YcaDudujEAVHKt3a3QJg1+sr/oX96TbaGUubG0hJyCjCBThFH+tFpcIyoUHUn1ogaLA==} - engines: {node: '>=20'} - string_decoder@1.1.1: resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} @@ -8582,10 +8504,6 @@ packages: resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} engines: {node: '>=12'} - wrap-ansi@9.0.2: - resolution: {integrity: sha512-42AtmgqjV+X1VpdOfyTGOYRi0/zsoLqtXQckTmqTeybT+BDIbM/Guxo7x3pE2vtpr1ok6xRqM9OpBe+Jyoqyww==} - engines: {node: '>=18'} - wrappy@1.0.2: resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} @@ -12235,10 +12153,6 @@ snapshots: dependencies: without-undefined-properties: 0.1.2 - ansi-escapes@7.2.0: - dependencies: - environment: 1.1.0 - ansi-regex@5.0.1: {} ansi-regex@6.2.2: {} @@ -12551,15 +12465,6 @@ snapshots: cjs-module-lexer@2.1.1: {} - cli-cursor@5.0.0: - dependencies: - restore-cursor: 5.1.0 - - cli-truncate@5.2.0: - dependencies: - slice-ansi: 8.0.0 - string-width: 8.2.1 - cli-width@4.1.0: {} clipanion@4.0.0-rc.4(typanion@3.14.0): @@ -12582,8 +12487,6 @@ snapshots: colorjs.io@0.7.1: {} - commander@14.0.3: {} - commander@2.20.3: {} commander@9.5.0: {} @@ -12861,8 +12764,6 @@ snapshots: optionalDependencies: node-addon-api: 7.1.1 - emoji-regex@10.6.0: {} - emoji-regex@8.0.0: {} emoji-regex@9.2.2: {} @@ -12895,8 +12796,6 @@ snapshots: entities@8.0.0: {} - environment@1.1.0: {} - errno@0.1.8: dependencies: prr: 1.0.1 @@ -13126,8 +13025,6 @@ snapshots: event-target-shim@5.0.1: {} - eventemitter3@5.0.4: {} - events-universal@1.0.1: dependencies: bare-events: 2.8.2 @@ -13312,8 +13209,6 @@ snapshots: get-caller-file@2.0.5: {} - get-east-asian-width@1.6.0: {} - get-github-auth-token@0.1.2: {} get-port@7.1.0: {} @@ -13529,10 +13424,6 @@ snapshots: is-fullwidth-code-point@3.0.0: {} - is-fullwidth-code-point@5.1.0: - dependencies: - get-east-asian-width: 1.6.0 - is-glob@4.0.3: dependencies: is-extglob: 2.1.1 @@ -13766,15 +13657,6 @@ snapshots: lilconfig@3.1.3: {} - lint-staged@16.4.0: - dependencies: - commander: 14.0.3 - listr2: 9.0.5 - picomatch: 4.0.7 - string-argv: 0.3.2 - tinyexec: 1.3.1 - yaml: 2.9.0 - lint-staged@17.5.1: dependencies: picomatch: 4.0.7 @@ -13783,15 +13665,6 @@ snapshots: optionalDependencies: yaml: 2.9.0 - listr2@9.0.5: - dependencies: - cli-truncate: 5.2.0 - colorette: 2.0.20 - eventemitter3: 5.0.4 - log-update: 6.1.0 - rfdc: 1.4.1 - wrap-ansi: 9.0.2 - loader-utils@3.3.1: {} local-pkg@1.2.1: @@ -13824,14 +13697,6 @@ snapshots: lodash@4.17.21: {} - log-update@6.1.0: - dependencies: - ansi-escapes: 7.2.0 - cli-cursor: 5.0.0 - slice-ansi: 7.1.2 - strip-ansi: 7.1.2 - wrap-ansi: 9.0.2 - loglevel-plugin-prefix@0.8.4: {} loglevel@1.9.2: {} @@ -13886,8 +13751,6 @@ snapshots: mime@1.6.0: optional: true - mimic-function@5.0.1: {} - minimatch@10.2.4: dependencies: brace-expansion: 5.0.3 @@ -14034,10 +13897,6 @@ snapshots: dependencies: wrappy: 1.0.2 - onetime@7.0.0: - dependencies: - mimic-function: 5.0.1 - open@10.2.0: dependencies: default-browser: 5.4.0 @@ -14599,15 +14458,8 @@ snapshots: dependencies: fast-deep-equal: 2.0.1 - restore-cursor@5.1.0: - dependencies: - onetime: 7.0.0 - signal-exit: 4.1.0 - ret@0.5.0: {} - rfdc@1.4.1: {} - rgb2hex@0.2.5: {} rolldown-plugin-dts@0.27.13(@typescript/native-preview@7.0.0-dev.20260605.1)(oxc-resolver@11.24.2)(rolldown@rolldown+packages+rolldown)(typescript@6.0.3): @@ -14914,16 +14766,6 @@ snapshots: sisteransi@1.0.5: {} - slice-ansi@7.1.2: - dependencies: - ansi-styles: 6.2.3 - is-fullwidth-code-point: 5.1.0 - - slice-ansi@8.0.0: - dependencies: - ansi-styles: 6.2.3 - is-fullwidth-code-point: 5.1.0 - slugify@1.6.6: {} smart-buffer@4.2.0: {} @@ -15033,17 +14875,6 @@ snapshots: emoji-regex: 9.2.2 strip-ansi: 7.1.2 - string-width@7.2.0: - dependencies: - emoji-regex: 10.6.0 - get-east-asian-width: 1.6.0 - strip-ansi: 7.1.2 - - string-width@8.2.1: - dependencies: - get-east-asian-width: 1.6.0 - strip-ansi: 7.1.2 - string_decoder@1.1.1: dependencies: safe-buffer: 5.1.2 @@ -15677,12 +15508,6 @@ snapshots: string-width: 5.1.2 strip-ansi: 7.1.2 - wrap-ansi@9.0.2: - dependencies: - ansi-styles: 6.2.3 - string-width: 7.2.0 - strip-ansi: 7.1.2 - wrappy@1.0.2: {} ws@8.21.1: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index 606a3a82dd..ead74cabbb 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -89,7 +89,7 @@ catalog: jsonc-parser: ^3.3.1 # Kept in lockstep with the bundled @tsdown/css by .github/scripts/upgrade-deps.ts lightningcss: ^1.33.0 - lint-staged: ^16.2.6 + lint-staged: ^17.5.1 lodash-es: ^4.17.21 micromatch: ^4.0.9 minimatch: ^10.0.3