-
Notifications
You must be signed in to change notification settings - Fork 21
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
Showing
4 changed files
with
43 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
registry=http://localhost:4873 | ||
auto-install-peers=false | ||
lockfile=false |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
npmRegistryServer: "http://localhost:4873" | ||
unsafeHttpWhitelist: ["localhost"] | ||
enableGlobalCache: false |
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 |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Make sure to create a .npmrc file | ||
# registry=http://localhost:4873 | ||
|
||
PACQUET="../target/release/pacquet add fastify" | ||
PNPM="pnpm add fastify --silent" | ||
YARN="yarn add fastify --silent" | ||
BUN="bun add fastify --no-cache --no-save --silent" | ||
|
||
FILE_CLEAN="rm -rf package.json node_modules .yarn yarn.lock .pnp* && echo {} > package.json || true" | ||
PNPM_CLEAN="pnpm store prune" | ||
YARN_CLEAN="yarn cache clean --all" | ||
CLEANUP="${PNPM_CLEAN} && ${YARN_CLEAN} && ${FILE_CLEAN}" | ||
|
||
$FILE_CLEAN | ||
|
||
hyperfine -w 5 -i \ | ||
--prepare "${CLEANUP}" \ | ||
-n pacquet "${PACQUET}" \ | ||
-n pnpm "${PNPM}" \ | ||
-n yarn "${YARN}" \ | ||
-n bun "${BUN}" | ||
|
||
$FILE_CLEAN |
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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
[install] | ||
optional = false | ||
dev = false | ||
# The following does not work | ||
#registry = "http://localhost:4873/" | ||
|
||
[install.cache] | ||
disable = true | ||
disableManifest = true | ||
|
||
[install.lockfile] | ||
save = false |