Skip to content

Commit

Permalink
fix(pnpm): url and git package specifiers
Browse files Browse the repository at this point in the history
  • Loading branch information
jbedard committed May 28, 2024
1 parent a7b0c1d commit 1750891
Show file tree
Hide file tree
Showing 12 changed files with 332 additions and 122 deletions.
8 changes: 0 additions & 8 deletions e2e/pnpm_lockfiles/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,6 @@

TODO:

- http references: `"hello": "https://gitpkg.vercel.app/EqualMa/gitpkg-hello/packages/hello"`

Has inconsistencies across pnpm lockfile versions, issues with pnpm9

- file references: `"@scoped/c": "file:../projects/c"`

Has inconsistencies across pnpm lockfile versions, issues with pnpm9

- npm: references: `@aspect-test/a2": "npm:@aspect-test/a"`

No :node_modules/\* targets are generated for aliases to npm packages.
Expand Down
2 changes: 2 additions & 0 deletions e2e/pnpm_lockfiles/base/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
"private": true,
"dependencies": {
"@aspect-test/a": "^5.0.2",
"debug": "ngokevin/debug#9742c5f383a6f8046241920156236ade8ec30d53",
"hello": "https://gitpkg.vercel.app/EqualMa/gitpkg-hello/packages/hello",
"rollup": "3.2.5",
"meaning-of-life": "1.0.0",
"uvu": "0.5.6",
Expand Down
13 changes: 12 additions & 1 deletion e2e/pnpm_lockfiles/lockfile-test.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,20 @@ def lockfile_test(name = None):
# link:, workspace:, file:, ./rel/path
":node_modules/@scoped/a",
":node_modules/@scoped/b",
# ":node_modules/@scoped/c", TODO: see README
":node_modules/@scoped/c",
":node_modules/@scoped/d",

# http:
":node_modules/debug",
# TODO: differs across lockfile versions
":.aspect_rules_js/node_modules/{}".format("[email protected]+ngokevin+debug+tar.gz+9742c5f383a6f8046241920156236ade8ec30d53" if lock_version == "v90" else "[email protected]+ngokevin+debug+9742c5f383a6f8046241920156236ade8ec30d53"),

# repo#hash
# (no protocol, assumed to be github repo + hash):
":node_modules/hello",
# TODO: differs across lockfile versions
":.aspect_rules_js/node_modules/{}".format("[email protected]+EqualMa+gitpkg-hello+packages+hello" if lock_version == "v90" else "@gitpkg.vercel.app+EqualMa+gitpkg-hello+packages+hello"),

# npm:
# ":node_modules/@aspect-test/c2",

Expand Down
27 changes: 27 additions & 0 deletions e2e/pnpm_lockfiles/v54/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

48 changes: 30 additions & 18 deletions e2e/pnpm_lockfiles/v54/snapshots/defs.bzl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

29 changes: 29 additions & 0 deletions e2e/pnpm_lockfiles/v60/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 1750891

Please sign in to comment.