From d8817c2d32a237440a7677622ba351aa95f47c22 Mon Sep 17 00:00:00 2001 From: Tiago Teixeira Date: Mon, 26 Jun 2023 01:43:39 +0200 Subject: Add support for install with --frozen-lockfile (#3365) * Add support for install with --frozen-lockfile * Add test * Add test for frozenLockfile in config file --- docs/install/index.md | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'docs/install') diff --git a/docs/install/index.md b/docs/install/index.md index 48e001275..162a4abac 100644 --- a/docs/install/index.md +++ b/docs/install/index.md @@ -49,6 +49,12 @@ To install in production mode (i.e. without `devDependencies`): $ bun install --production ``` +To install dependencies without allowing changes to lockfile (useful on CI): + +```bash +$ bun install --frozen-lockfile +``` + To perform a dry run (i.e. don't actually install anything): ```bash @@ -80,6 +86,9 @@ peer = false # equivalent to `--production` flag production = false +# equivalent to `--frozen-lockfile` flag +frozenLockfile = false + # equivalent to `--dry-run` flag dryRun = false ``` -- cgit v1.2.3 From 609f81a74614b20a1d49ce1197e1ddfe5aa2736f Mon Sep 17 00:00:00 2001 From: Colin McDonnell Date: Tue, 11 Jul 2023 15:32:41 -0700 Subject: Add npmrc note --- docs/api/file-io.md | 12 ++++++++++-- docs/install/registries.md | 4 ++++ 2 files changed, 14 insertions(+), 2 deletions(-) (limited to 'docs/install') diff --git a/docs/api/file-io.md b/docs/api/file-io.md index effc57580..be9cf0991 100644 --- a/docs/api/file-io.md +++ b/docs/api/file-io.md @@ -285,7 +285,13 @@ interface Bun { write( destination: string | number | BunFile | URL, - input: string | Blob | ArrayBuffer | SharedArrayBuffer | TypedArray | Response, + input: + | string + | Blob + | ArrayBuffer + | SharedArrayBuffer + | TypedArray + | Response, ): Promise; } @@ -301,7 +307,9 @@ interface BunFile { } export interface FileSink { - write(chunk: string | ArrayBufferView | ArrayBuffer | SharedArrayBuffer): number; + write( + chunk: string | ArrayBufferView | ArrayBuffer | SharedArrayBuffer, + ): number; flush(): number | Promise; end(error?: Error): number | Promise; start(options?: { highWaterMark?: number }): void; diff --git a/docs/install/registries.md b/docs/install/registries.md index e4090e3c9..86657ca26 100644 --- a/docs/install/registries.md +++ b/docs/install/registries.md @@ -24,3 +24,7 @@ To configure a private registry scoped to a particular organization: # registry with token "@myorg3" = { token = "$npm_token", url = "https://registry.myorg.com/" } ``` + +### `.npmrc` + +Bun does not currently read `.npmrc` files. For private registries, migrate your registry configuration to `bunfig.toml` as documented above. -- cgit v1.2.3