mirror of
https://github.com/pnpm/pnpm.git
synced 2026-06-28 09:55:39 -04:00
External processes like SSH passphrase prompts can write to the terminal between progress updates. The previous renderer used `ansi-diff`, which only overwrites the characters it knows changed, so leftover characters from the external output stayed visible on the progress line — e.g. `added 0sa':`, where `sa':` is a fragment of `Enter passphrase for key '.../.ssh/id_rsa':`. Closes https://github.com/pnpm/pnpm/issues/12350 ## Summary The interactive (non-append-only) reporter now redraws the whole frame in place on each update instead of incrementally diffing it: - return the cursor to the top-left of the previous frame (`ESC[<rows>A` followed by a carriage return, so the redraw starts at column 0 even if an external process left the cursor mid-line), - erase from there to the end of the display (`ESC[0J`), - reprint the frame — all in a single atomic write, so there is no flicker. Because the whole region is erased on every frame, any characters an external process wrote in between are cleared. This matches pacquet's `Output::Frame` rendering (the column-reset hardening was applied to both stacks). The now-unused `ansi-diff` dependency has been removed. --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> Co-authored-by: Zoltan Kochan <z@kochan.io>
82 lines
2.3 KiB
JSON
82 lines
2.3 KiB
JSON
{
|
|
"name": "@pnpm/cli.default-reporter",
|
|
"version": "1100.3.1",
|
|
"description": "The default reporter of pnpm",
|
|
"keywords": [
|
|
"pnpm",
|
|
"pnpm11",
|
|
"pnpm-reporter"
|
|
],
|
|
"license": "MIT",
|
|
"funding": "https://opencollective.com/pnpm",
|
|
"repository": "https://github.com/pnpm/pnpm/tree/main/cli/default-reporter",
|
|
"homepage": "https://github.com/pnpm/pnpm/tree/main/cli/default-reporter#readme",
|
|
"bugs": {
|
|
"url": "https://github.com/pnpm/pnpm/issues"
|
|
},
|
|
"type": "module",
|
|
"main": "lib/index.js",
|
|
"types": "lib/index.d.ts",
|
|
"exports": {
|
|
".": "./lib/index.js"
|
|
},
|
|
"files": [
|
|
"lib",
|
|
"!*.map",
|
|
"bin"
|
|
],
|
|
"bin": {
|
|
"pnpm-render": "bin/pnpm-render.mjs"
|
|
},
|
|
"scripts": {
|
|
"start": "tsgo --watch",
|
|
"lint": "eslint \"src/**/*.ts\" \"test/**/*.ts\"",
|
|
"test": "pn compile && pn .test",
|
|
"prepublishOnly": "tsgo --build",
|
|
"compile": "tsgo --build && pn lint --fix",
|
|
".test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules --disable-warning=ExperimentalWarning --disable-warning=DEP0169\" jest"
|
|
},
|
|
"dependencies": {
|
|
"@pnpm/cli.meta": "workspace:*",
|
|
"@pnpm/config.reader": "workspace:*",
|
|
"@pnpm/core-loggers": "workspace:*",
|
|
"@pnpm/deps.inspection.peers-issues-renderer": "workspace:*",
|
|
"@pnpm/error": "workspace:*",
|
|
"@pnpm/installing.dedupe.issues-renderer": "workspace:*",
|
|
"@pnpm/installing.dedupe.types": "workspace:*",
|
|
"@pnpm/types": "workspace:*",
|
|
"@pnpm/util.lex-comparator": "catalog:",
|
|
"boxen": "catalog:",
|
|
"chalk": "catalog:",
|
|
"cli-truncate": "catalog:",
|
|
"normalize-path": "catalog:",
|
|
"pretty-bytes": "catalog:",
|
|
"pretty-ms": "catalog:",
|
|
"ramda": "catalog:",
|
|
"rxjs": "catalog:",
|
|
"semver": "catalog:",
|
|
"stacktracey": "catalog:",
|
|
"string-length": "catalog:"
|
|
},
|
|
"peerDependencies": {
|
|
"@pnpm/logger": "catalog:"
|
|
},
|
|
"devDependencies": {
|
|
"@jest/globals": "catalog:",
|
|
"@pnpm/cli.default-reporter": "workspace:*",
|
|
"@pnpm/logger": "workspace:*",
|
|
"@types/normalize-path": "catalog:",
|
|
"@types/ramda": "catalog:",
|
|
"@types/semver": "catalog:",
|
|
"ghooks": "catalog:",
|
|
"load-json-file": "catalog:",
|
|
"normalize-newline": "catalog:"
|
|
},
|
|
"engines": {
|
|
"node": ">=22.13"
|
|
},
|
|
"jest": {
|
|
"preset": "@pnpm/jest-config"
|
|
}
|
|
}
|