Skip to content

chore: pre pnpm cleanup#4759

Merged
escapedcat merged 6 commits into
masterfrom
chore/pre-pnpm-cleanup
May 12, 2026
Merged

chore: pre pnpm cleanup#4759
escapedcat merged 6 commits into
masterfrom
chore/pre-pnpm-cleanup

Conversation

@escapedcat

@escapedcat escapedcat commented May 12, 2026

Copy link
Copy Markdown
Member
  1. Drop @types/conventional-commits-parser — cc-parser v6 ships its own types
  2. Declare @types/node in 7 packages that import node:*
  3. Declare rxjs in @commitlint/prompt
  4. Declare conventional-commits-parser in @commitlint/cli
  5. Declare vitest-environment-commitlint at root
  6. Declare @commitlint/config-conventional and @commitlint/config-workspace-scopes at root

escapedcat and others added 6 commits May 12, 2026 11:33
conventional-commits-parser v6 ships its own type definitions
(see exports.types in its package.json), so the DefinitelyTyped
@types/conventional-commits-parser package is shadowed and adds
no value. Remove it from the four packages that still list it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Seven packages import from node:* modules (node:module, node:util,
node:readline, node:fs, node:os, node:path, node:url, node:child_process,
node:process) but rely on yarn's hoisting to resolve @types/node.
Declare it explicitly so the dependency is honest and the packages
build under any package manager.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@commitlint/prompt's InputCustomPrompt imports type Subscription
from "rxjs" but does not declare rxjs in its package.json. The
package resolves today only because inquirer transitively pulls it
in and yarn hoists it. Declare it explicitly to make the dependency
honest.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@commitlint/cli imports type ParserOptions from "conventional-commits-parser"
but does not declare the package. It resolves today only because
@commitlint/types lists it as a runtime dep and yarn hoists it.
Declare it explicitly as a devDependency (type-only import).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The root vitest config sets environment: "commitlint", which loads
vitest-environment-commitlint (the workspace package at
@packages/test-environment). Declare it at root so the dependency
is honest and resolves under any package manager, not only via
yarn's workspace hoisting.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The root commitlint.extends list references @commitlint/config-conventional
and @commitlint/config-workspace-scopes, but neither is declared in the
root devDependencies. They resolve today only because yarn workspaces
hoist them. Declare them explicitly so the root config is self-contained.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@qodo-code-review

Copy link
Copy Markdown
ⓘ You've reached your Qodo monthly free-tier limit. Reviews pause until next month — upgrade your plan to continue now, or link your paid account if you already have one.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR prepares the repo for a pnpm-oriented dependency layout by making TypeScript/runtime dependency declarations more explicit across workspaces (and removing now-redundant types packages).

Changes:

  • Removed @types/conventional-commits-parser usage/lockfile entry (parser v6 provides its own types).
  • Added @types/node to several workspace packages that import node:* modules.
  • Added missing dev deps used for type imports/tests/config (rxjs, conventional-commits-parser, vitest-environment-commitlint, and root commitlint configs).

Reviewed changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated no comments.

Show a summary per file
File Description
yarn.lock Removes the now-unused @types/conventional-commits-parser resolution entry.
package.json Adds root devDeps for commitlint configs and vitest-environment-commitlint.
@commitlint/types/package.json Drops @types/conventional-commits-parser devDep (types come from conventional-commits-parser).
@commitlint/travis-cli/package.json Adds @types/node devDep for Node ESM imports/types usage.
@commitlint/top-level/package.json Adds @types/node devDep for Node ESM imports/types usage.
@commitlint/rules/package.json Replaces @types/conventional-commits-parser with @types/node in devDeps.
@commitlint/resolve-extends/package.json Adds @types/node devDep for Node ESM imports/types usage.
@commitlint/prompt/package.json Adds @types/node and rxjs devDeps for type-only imports.
@commitlint/parse/package.json Drops @types/conventional-commits-parser devDep (parser v6 types).
@commitlint/lint/package.json Adds @types/node devDep for Node ESM imports/types usage.
@commitlint/config-validator/package.json Adds @types/node devDep for Node ESM imports/types usage.
@commitlint/cli/package.json Adds conventional-commits-parser devDep to satisfy type-only import resolution.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@escapedcat escapedcat merged commit db39968 into master May 12, 2026
19 checks passed
@escapedcat escapedcat deleted the chore/pre-pnpm-cleanup branch May 12, 2026 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants