feat(pacquet): implement bugs command (#12687)

Port the `pnpm bugs` command to pacquet, following the structure of the TypeScript handler at `pnpm11/deps/inspection/commands/src/bugs/index.ts` and matching its error codes (`ERR_PNPM_NO_BUGS_URL`, `ERR_PNPM_NO_IMPORTER_MANIFEST_FOUND`). The command supports local manifest lookup and registry lookup by package name, with repository URL normalization for GitHub/GitLab/Bitbucket shorthand, hosted git URLs, and self-hosted git servers. Unit tests cover all URL derivation branches (36 tests). Integration tests cover the CLI entry points with local manifests and a mocked registry (9 tests).

Related to pnpm/pnpm#11633.
This commit is contained in:
Alessio Attilio
2026-07-01 18:09:02 +02:00
committed by GitHub
parent 397f9783f4
commit ddbb4899c2
24 changed files with 1141 additions and 142 deletions

View File

@@ -43,7 +43,7 @@ jobs:
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- uses: garnet-org/action@2b7fc9d79b54f551b43358c27424a36064b3e078 # v2
- uses: garnet-org/action@2b7fc9d79b54f551b43358c27424a36064b3e078 # v2.0.2
with:
api_token: ${{ secrets.GARNET_API_TOKEN }}
- name: Install pnpm and Node

View File

@@ -60,7 +60,7 @@ jobs:
with:
persist-credentials: false
- if: ${{ inputs.garnet }}
uses: garnet-org/action@2b7fc9d79b54f551b43358c27424a36064b3e078 # v2
uses: garnet-org/action@2b7fc9d79b54f551b43358c27424a36064b3e078 # v2.0.2
with:
api_token: ${{ secrets.GARNET_API_TOKEN }}
- name: Install pnpm and Node

View File

@@ -18,7 +18,7 @@ jobs:
environment: release
runs-on: ubuntu-latest
steps:
- uses: garnet-org/action@2b7fc9d79b54f551b43358c27424a36064b3e078 # v2
- uses: garnet-org/action@2b7fc9d79b54f551b43358c27424a36064b3e078 # v2.0.2
with:
api_token: ${{ secrets.GARNET_API_TOKEN }}
- name: Setup Node