Install Turborepo
turbo
works with yarn (opens in a new tab), npm (opens in a new tab), and pnpm (opens in a new tab) on the following operating systems:
- macOS darwin 64-bit (Intel), ARM 64-bit (Apple Silicon)
- Linux 64-bit, ARM 64-bit
- Windows 64-bit, ARM 64-bit
Install Globally
A global install of turbo
can be used in any project, and enables automatic workspace
selection based on the directory where you run turbo
.
npm install turbo --global
Once you have a globally installed copy of turbo
, you will be able to run directly from workspace
directories.
cd <repository root>/apps/docs
turbo build
is equivalent to the filtering syntax:
cd <repository root>
turbo build --filter=docs
If you've installed global turbo
before, make sure you use the same package manager as your existing installation to avoid unexpected behaviors. For more info, visit the FAQ.
Install Per Repository
You may wish to pin the version of Turborepo used within a repository, especially if you are
collaborating with other developers. In that case, add turbo
as a dev dependency at the root
of the repository:
npm install turbo --save-dev
You can continue to use your global install of turbo
, which will defer to your local version
if it exists. This allows you to get the best of both worlds: easy scoping to the directory you're working
in while maintaining a pinned version among your entire team.