Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: npm/cli
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v11.5.2
Choose a base ref
...
head repository: npm/cli
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v11.6.0
Choose a head ref
  • 11 commits
  • 47 files changed
  • 11 contributors

Commits on Aug 4, 2025

  1. fix: ps1 scripts in powershell 5.1 (#8469)

    Fixes issue #8468: npm.ps1 and npx.ps1 fail on Windows PowerShell 5.1 when run in strict mode.
    splatteredbits authored Aug 4, 2025
    Configuration menu
    Copy the full SHA
    5d82d0b View commit details
    Browse the repository at this point in the history

Commits on Aug 19, 2025

  1. fix(arborist): #8472 Keeps the registry protocol when modifying resol…

    …ve URL (#8473)
    
    Fix an issue where the configured registry protocol does not follow when
    resolving a package resolved url.
    
    ## References
      Fixes #8472
    
    Co-authored-by: Jean-Philippe Boucher <jeanphilippe.boucher@cauca.ca>
    Jeepsboucher and Jean-Philippe Boucher authored Aug 19, 2025
    Configuration menu
    Copy the full SHA
    ed71acb View commit details
    Browse the repository at this point in the history

Commits on Aug 22, 2025

  1. fix: revert handle signal exits gracefully (#8524)

    This reverts commit c8d8397.
    owlstronaut authored Aug 22, 2025
    Configuration menu
    Copy the full SHA
    75ce64a View commit details
    Browse the repository at this point in the history

Commits on Aug 27, 2025

  1. fix: installLinks works with transitive external file dependencies (#…

    …8534)
    
    fixes #8342
    
    What
    This PR fixes an issue where npm fails to properly handle transitive
    file dependencies when using the --install-links flag. Previously, when
    a file dependency had its own file dependencies, npm would fail to
    resolve them correctly, resulting in `ERR_MODULE_NOT_FOUND` errors.
    
    Why
    When using `npm install --install-links` to install a local package that
    has its own file dependencies, npm would attempt to resolve the
    transitive dependencies relative to the installed location in
    `node_modules` rather than the original source location. This caused the
    installation to fail because the transitive dependencies couldn't be
    found at the incorrect path.
    
    For example, given this structure:
    
    Running `npm install --install-links ../b` from `mainpkg` would fail
    because npm tried to find a relative to `b` instead of relative to the
    original `b` source location.
    
    How
    The fix introduces logic to detect transitive file dependencies when
    `--install-links` is used and ensures they are resolved relative to
    their parent's original source location:
    
    Detect transitive file dependencies: When a parent package was installed
    (not linked) due to `--install-links` and has file dependencies of its
    own, those are identified as transitive file dependencies.
    
    Preserve original paths: The parent's resolved` field (e.g., file:../b)
    is used to determine the original source location.
    
    Correct path resolution: Transitive file dependencies are resolved
    relative to the parent's original location rather than its installed
    location in `node_modules`
    owlstronaut authored Aug 27, 2025
    Configuration menu
    Copy the full SHA
    3b54e9c View commit details
    Browse the repository at this point in the history

Commits on Aug 28, 2025

  1. Configuration menu
    Copy the full SHA
    9e5abf1 View commit details
    Browse the repository at this point in the history
  2. fix: peer edge crash due to no parent or detached node (#8448)

    `node.parent` is resulting in `null` value somewhere in recursive/looped
    calls to `#loadPeerSet` method in building ideal tree.
    
    When circular peer ref of a top level dependency replaced/resolved with
    different compatible version, it makes top level dependency to be
    removed from it's parent ( node.parent = null ) since it's been
    replaced, so no longer need to proceed with further peer set
    exploration.
    
    fixes: #8261
    milaninfy authored Aug 28, 2025
    Configuration menu
    Copy the full SHA
    208c06e View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    5f18557 View commit details
    Browse the repository at this point in the history

Commits on Sep 2, 2025

  1. fix(powershell): improve argument parsing (#8539)

    improve the argument parsing PS1 logic
    - support `& npm args` and `. npm args` properly
    - support syntax such as `C:\"Program Files"\nodejs\npm.ps1 args`
    
    **of course ^ for both npm and npx version of the script**
    
    Code Explanation: instead of getting the `CommandElements.Extent.Text`
    array and joining it with spaces right away, now it's getting the same
    array and only capturing everything after the first element
    alexsch01 authored Sep 2, 2025
    Configuration menu
    Copy the full SHA
    dd4cee9 View commit details
    Browse the repository at this point in the history

Commits on Sep 3, 2025

  1. feat: add support for optional env var replacements in .npmrc (#8359)

    <!-- What / Why -->
    This solves problem described in #8335 in a backwards-compatible way.
    
    <!-- Describe the request in detail. What it does and why it's being
    changed. -->
    This PR adds possibility to have env var replacements in .npmrc configs
    written as `${VAR?}` which will cause them to get replaced with an empty
    string if the variable is not defined. Old behavior where undefined
    variables are left unreplaced is not changed.
    
    ## References
    <!-- Examples:
      Related to #0
      Depends on #0
      Blocked by #0
      Fixes #0
      Closes #0
    -->
    Fixes #8335
    
    ---------
    
    Co-authored-by: Michael Smith <owlstronaut@github.com>
    aczekajski and owlstronaut authored Sep 3, 2025
    Configuration menu
    Copy the full SHA
    bdcc10d View commit details
    Browse the repository at this point in the history
  2. chore: fix pruner and reify tests for optional peer deps (#8540)

    While investigating CI failure in #8537,
    I found unrelated test failures when running locally on windows.
    
    `prune with lockfile with implicit optional peer dependencies` fixed by
    adding files to fixture `node_modules`, avoiding network, also reduced
    package lock to minimum and removed unhelpful snapshots
    
    `move aside symlink clutter` fixed by creating problematic symlink in
    `t.testdir()` instead of in `reifyPackages` hook
    
    ---------
    
    Co-authored-by: Liam Mitchell <liam.mitchell@mendix.com>
    liamcmitchell and liamcmitchell authored Sep 3, 2025
    Configuration menu
    Copy the full SHA
    619d43e View commit details
    Browse the repository at this point in the history
  3. chore: release 11.6.0

    github-actions[bot] authored and owlstronaut committed Sep 3, 2025
    Configuration menu
    Copy the full SHA
    3b30e0b View commit details
    Browse the repository at this point in the history
Loading