diff options
author | 2023-04-13 18:26:45 -0700 | |
---|---|---|
committer | 2023-04-13 18:26:45 -0700 | |
commit | 011e157cac7698050370e24495a9002dacfceea9 (patch) | |
tree | ebb561dbda3e8f67302cc4d5b398f4a2744f7884 /docs/install/registries.md | |
parent | 0cc56e8efce9c7d4905b3649827bf9b40a677b25 (diff) | |
download | bun-011e157cac7698050370e24495a9002dacfceea9.tar.gz bun-011e157cac7698050370e24495a9002dacfceea9.tar.zst bun-011e157cac7698050370e24495a9002dacfceea9.zip |
Docs restructuring (#2638)
* Restructure
* Update nav
* Reorg
* Reshuffle ecosystem pages
* Split up runtime/runtime
* Back to runtime/index
* Fix issue
* Split up runtime/index
* Add Writing Tests page
* Prettier matcher table
* More updates
Diffstat (limited to 'docs/install/registries.md')
-rw-r--r-- | docs/install/registries.md | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/docs/install/registries.md b/docs/install/registries.md new file mode 100644 index 000000000..e4090e3c9 --- /dev/null +++ b/docs/install/registries.md @@ -0,0 +1,26 @@ +The default registry is `registry.npmjs.org`. This can be globally configured in `bunfig.toml`: + +```toml +[install] +# set default registry as a string +registry = "https://registry.npmjs.org" +# set a token +registry = { url = "https://registry.npmjs.org", token = "123456" } +# set a username/password +registry = "https://username:password@registry.npmjs.org" +``` + +To configure a private registry scoped to a particular organization: + +```toml +[install.scopes] +# registry as string +"@myorg1" = "https://username:password@registry.myorg.com/" + +# registry with username/password +# you can reference environment variables +"@myorg2" = { username = "myusername", password = "$NPM_PASS", url = "https://registry.myorg.com/" } + +# registry with token +"@myorg3" = { token = "$npm_token", url = "https://registry.myorg.com/" } +``` |