Skip to content

Commit

Permalink
BREAKING: rewrite npm ls
Browse files Browse the repository at this point in the history
- Rewrites lib/ls.js command to use @npmcli/arborist
- Updates unit tests
- Breaking changes:
  - added error codes: ELSPROBLEMS, EJSONPARSE to callback errors
  - extraneous deps depth will match current location in nm folder
  - mark top-level deps as extraneous when missing root package.json
  - don't mark deps as extraneous if they're valid deps of invalid deps
  - peer deps are now listed as regular deps, removed oddities such as
  peerinvalid label and stops labeling peer deps extraneous
  - might print diff git resolved values,
  see: https://github.com/npm/hosted-git-info
  - Parseable (--parseable) output:
    - possible order of printed elements changed
    - fixed consistency problems in which it would print root folder
    name if using a filter argument that could not match against
    any of the deps in the current installed tree
    - fixed printing non-existing paths for missing dependencies
    - fixed undefined symlink output when using --long output
  - JSON (--json) output:
    - removed: `from` property from --json output
    - removed: "[Circular]" references
    - added "missing" to list of peer-dep problems listed
    - added peerDependencies ref when using --long output
    - removed readme properties using --long output
    - Renamed error msg:
    `Failed to parse json` -> `Failed to parse root package.json`

refs:
  - npm/statusboard#99
  - npm/statusboard#103
  • Loading branch information
ruyadorno committed Jul 21, 2020
1 parent 7fbd867 commit 433c5e5
Show file tree
Hide file tree
Showing 3 changed files with 1,200 additions and 675 deletions.
Loading

0 comments on commit 433c5e5

Please sign in to comment.