diff options
author | Nathan Whitaker <17734409+nathanwhit@users.noreply.github.com> | 2024-05-29 17:45:22 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-29 17:45:22 -0700 |
commit | a379009bfdddc56d6400740ad7be86f8930952ab (patch) | |
tree | a1198bce9d62d9c2a59073921707c31b894c8eee /tests/specs/npm/bin_entries_prefer_closer/install.out | |
parent | e084fe10a98556d4630b54bdda2ce23b3b5b8a60 (diff) |
fix(cli): Prefer npm bin entries provided by packages closer to the root (#24024)
Fixes #24012.
In the case of multiple packages providing a binary with a same name, we
were basically leaving the results undefined (since we set up things in
parallel, and whichever got set up first won). In addition, we were
warning about these cases, even though it's a situation that's expected
to occur.
Instead, in the case of a collision in the binary names, we prefer the
binary provided by the package with the least depth in the dependency
tree.
While I was at it, I also took moved more code to `bin_entries.rs` since
it was starting to get a bit cluttered.
Diffstat (limited to 'tests/specs/npm/bin_entries_prefer_closer/install.out')
-rw-r--r-- | tests/specs/npm/bin_entries_prefer_closer/install.out | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/specs/npm/bin_entries_prefer_closer/install.out b/tests/specs/npm/bin_entries_prefer_closer/install.out new file mode 100644 index 000000000..25e06db99 --- /dev/null +++ b/tests/specs/npm/bin_entries_prefer_closer/install.out @@ -0,0 +1,11 @@ +⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag. +[UNORDERED_START] +Download http://localhost:4260/@denotest/transitive-bin +Download http://localhost:4260/@denotest/bin +Download http://localhost:4260/@denotest/bin/1.0.0.tgz +Download http://localhost:4260/@denotest/transitive-bin/1.0.0.tgz +Download http://localhost:4260/@denotest/bin/0.7.0.tgz +Initialize @denotest/transitive-bin@1.0.0 +Initialize @denotest/bin@1.0.0 +Initialize @denotest/bin@0.7.0 +[UNORDERED_END] |