Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Noting multiple global turbo installations. #5119

Merged
merged 1 commit into from
May 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions docs/pages/repo/docs/faq.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ description: Frequently asked questions about Turborepo.
---

import Callout from '../../../components/Callout'
import { Tabs, Tab } from '../../../components/Tabs'

# Frequently Asked Questions

Expand All @@ -16,6 +17,35 @@ You have two options when working with Turborepo:

We recommend installing the `turbo` CLI globally. This gives you a smooth, ergonomic experience for running tasks.

### Why isn't my global `turbo` working as expected?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another issue I've seen here is caused by the order that the global bin directory is referenced in your PATH. For example if yarn is included before pnpm, and you update turbo via pnpm, your version isn't going to change because turbo is going to resolve to the yarn version first.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a dev-only issue but I often end up with turbo in my .cargo/bin as well...


It's possible to end up with multiple versions of global `turbo` on your machine if you install with different package managers. This can cause unexpected behavior if you're accidentally executing an older version of `turbo`.

You can quickly check which package manager's version you are using with:

- macOS and Linux: `which turbo`
- Windows: `where turbo`

The easiest way to ensure stability is to run the uninstall commands for your non-preferred package managers:

<Tabs items={['npm', 'yarn', 'pnpm']} storageKey="selected-pkg-manager">
<Tab>
```bash
npm uninstall turbo --global
```
</Tab>
<Tab>
```bash
yarn global remove turbo
```
</Tab>
<Tab>
```bash
pnpm uninstall turbo --global
```
</Tab>
</Tabs>

## Do I have to use Remote Caching to use Turborepo?

No. [Remote Caching](/repo/docs/core-concepts/remote-caching) is optional. However, you'll find it very useful to speed up development on a team, speed up builds inside of Docker, and also save space on your own machine.
Expand Down
2 changes: 2 additions & 0 deletions docs/pages/repo/docs/installing.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ 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](/repo/docs/faq#should-i-install-turborepo-globally).

## Install Per Repository

You may wish to pin the version of Turborepo used within a repository, especially [if you are
Expand Down
Loading