-
Notifications
You must be signed in to change notification settings - Fork 106
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2779e24
commit 4f19ab4
Showing
3 changed files
with
33 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -147,23 +147,36 @@ var ( | |
// npm pack | ||
// mkdir -p /app/foo/bar && cd /app | ||
// cp /temp/node_modules/lodash/lodash-4.17.21.tgz /app/foo/bar/lodash.tgz | ||
// npm init -y | ||
// npm install ./foo/bar/lodash.tgz | ||
// mkdir package1 && cd package1 | ||
// npm init -y | ||
// npm install [email protected] | ||
// cd .. | ||
// npm install ./package1 | ||
// pnpm update | ||
// pnpm add https://github.com/debug-js/debug/tarball/4.3.4 | ||
// pnpm add https://codeload.github.com/zkochan/is-negative/tar.gz/2fa0531ab04e300a24ef4fd7fb3a280eccb7ccc5 | ||
// pnpm list --prod --depth 10 | grep -E -o "\S+\s+[0-9]+(\.[0-9]+)+$" | awk '{printf("{ID: \""$1"@"$2"\", Name: \""$1"\", Version: \""$2"\", Indirect: false},\n")}' | sort -u | ||
// manually update `Indirect` fields | ||
pnpmArchives = []types.Library{ | ||
{ID: "[email protected]", Name: "asynckit", Version: "0.4.0", Indirect: true}, | ||
{ID: "[email protected]", Name: "debug", Version: "4.3.4", Indirect: false}, | ||
{ID: "[email protected]", Name: "is-negative", Version: "2.0.1", Indirect: false}, | ||
{ID: "[email protected]", Name: "lodash", Version: "4.17.21", Indirect: false}, | ||
{ID: "[email protected]", Name: "ms", Version: "2.1.2", Indirect: true}, | ||
{ID: "[email protected]", Name: "package1", Version: "1.0.0", Indirect: false}, | ||
} | ||
|
||
pnpmArchivesDeps = []types.Dependency{ | ||
{ | ||
ID: "[email protected]", | ||
DependsOn: []string{"[email protected]"}, | ||
}, | ||
{ | ||
ID: "[email protected]", | ||
DependsOn: []string{"[email protected]"}, | ||
}, | ||
} | ||
|
||
// docker run --name node --rm -it node@sha256:710a2c192ca426e03e4f3ec1869e5c29db855eb6969b74e6c50fd270ffccd3f1 sh | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,9 +10,16 @@ dependencies: | |
lodash: | ||
specifier: file:foo/bar/lodash.tgz | ||
version: file:foo/bar/lodash.tgz | ||
package1: | ||
specifier: file:package1 | ||
version: file:package1 | ||
|
||
packages: | ||
|
||
/[email protected]: | ||
resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} | ||
dev: false | ||
|
||
/[email protected]: | ||
resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} | ||
dev: false | ||
|
@@ -42,4 +49,12 @@ packages: | |
resolution: {integrity: sha512-fPftOkGbplay6FszUHWPJ8wV7liS+n2gB/UVN0Wv4G71KJWx+8trhGYsbekWqz6TTzkKur67bAdSIIccmKIyLA==, tarball: file:foo/bar/lodash.tgz} | ||
name: lodash | ||
version: 4.17.21 | ||
dev: false | ||
dev: false | ||
|
||
file:package1: | ||
resolution: {directory: package1, type: directory} | ||
name: package1 | ||
version: 1.0.0 | ||
dependencies: | ||
asynckit: 0.4.0 | ||
dev: false |