bun install CLI Usage
sh
bun install <name>@<version>General Configuration
--configstring Specify path to config file (bunfig.toml)
--cwdstring Set a specific cwd
Dependency Scope & Management
--productionboolean Don't install devDependencies
--no-saveboolean Don't update package.json or save a lockfile
--saveboolean default: true Save to package.json
--omitstring Exclude 'dev', 'optional', or 'peer' dependencies from install
--only-missingboolean Only add dependencies to package.json if they are not already present
Dependency Type & Versioning
--devboolean Add dependency to "devDependencies"
--optionalboolean Add dependency to "optionalDependencies"
--peerboolean Add dependency to "peerDependencies"
--exactboolean Add the exact version instead of the ^range
Lockfile Control
--yarnboolean Write a yarn.lock file (yarn v1)
--frozen-lockfileboolean Disallow changes to lockfile
--save-text-lockfileboolean Save a text-based lockfile
--lockfile-onlyboolean Generate a lockfile without installing dependencies
Network & Registry Settings
--castring Provide a Certificate Authority signing certificate
--cafilestring File path to Certificate Authority signing certificate
--registrystring Use a specific registry by default, overriding .npmrc, bunfig.toml and environment variables
Installation Process Control
--dry-runboolean Don't install anything
--forceboolean Always request the latest versions from the registry & reinstall all dependencies
--globalboolean Install globally
--backendstring default: clonefile Platform-specific optimizations: "clonefile", "hardlink", "symlink", "copyfile"
--filterstring Install packages for the matching workspaces
--analyzeboolean Analyze & install all dependencies of files passed as arguments recursively
Caching Options
--cache-dirstring Store & load cached data from a specific directory path
--no-cacheboolean Ignore manifest cache entirely
Output & Logging
--silentboolean Don't log anything
--verboseboolean Excessively verbose logging
--no-progressboolean Disable the progress bar
--no-summaryboolean Don't print a summary
Security & Integrity
--no-verifyboolean Skip verifying integrity of newly downloaded packages
--trustboolean Add to trustedDependencies in the project's package.json and install the package(s)
Concurrency & Performance
--concurrent-scriptsnumber default: 5 Maximum number of concurrent jobs for lifecycle scripts
--network-concurrencynumber default: 48 Maximum number of concurrent network requests
Lifecycle Script Management
--ignore-scriptsboolean Skip lifecycle scripts in the project's package.json (dependency scripts are never run)
Help Information
--helpboolean Print this help menu