Skip to content

Commit

Permalink
Rename /features to /core-concepts (vercel#1133)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredpalmer authored Apr 27, 2022
1 parent b8eeafb commit f389841
Show file tree
Hide file tree
Showing 23 changed files with 58 additions and 53 deletions.
2 changes: 1 addition & 1 deletion cli/internal/login/link.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func (l *link) run() error {
l.ui.Info(" all your team’s Vercel projects. It also can share outputs")
l.ui.Info(" with other services that enable Remote Caching, like CI/CD systems.")
l.ui.Info(" This results in faster build times and deployments for your team.")
l.ui.Info(util.Sprintf(" For more info, see ${UNDERLINE}https://turborepo.org/docs/features/remote-caching${RESET}"))
l.ui.Info(util.Sprintf(" For more info, see ${UNDERLINE}https://turborepo.org/docs/core-concepts/remote-caching${RESET}"))
l.ui.Info("")
currentDir, err := filepath.Abs(".")
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion cli/internal/login/login.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ func loginSSO(c *config.Config, ssoTeam string, deps loginDeps) error {
deps.ui.Info(" all your team’s Vercel projects. It also can share outputs")
deps.ui.Info(" with other services that enable Remote Caching, like CI/CD systems.")
deps.ui.Info(" This results in faster build times and deployments for your team.")
deps.ui.Info(util.Sprintf(" For more info, see ${UNDERLINE}https://turborepo.org/docs/features/remote-caching${RESET}"))
deps.ui.Info(util.Sprintf(" For more info, see ${UNDERLINE}https://turborepo.org/docs/core-concepts/remote-caching${RESET}"))
deps.ui.Info("")
deps.ui.Info(util.Sprintf("${GREY}To disable Remote Caching, run `npx turbo unlink`${RESET}"))
} else {
Expand Down
5 changes: 5 additions & 0 deletions docs/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ module.exports = withNextra({
permanent: true,
destination: "/docs/ci",
},
{
source: "/docs/features/:path*",
permanent: true,
destination: "/docs/core-concepts/:path*",
},
];
},
});
4 changes: 2 additions & 2 deletions docs/pages/blog/turbo-1-1-0.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ For more information on this transformation, [check out the documentation](https

When you use `turbo` with tools that inline environment variables at build time (e.g. Next.js or Create React App), it is important you tell `turbo` about it to avoid shipping a cached artifact with the wrong environment variables.

You can now control `turbo`'s [cache fingerprinting (a.k.a. hashing)](https://turborepo.org/docs/features/caching#hashing) behavior based on the values of both environment variables and the contents of files:
You can now control `turbo`'s [cache fingerprinting (a.k.a. hashing)](https://turborepo.org/docs/core-concepts/caching#hashing) behavior based on the values of both environment variables and the contents of files:

- Including environment variables in a `dependsOn` in your `pipeline` definition prefixed by a `$` will impact the cache fingerprint on a per-task or per-package-task basis.
- Including environment variables in `globalDependencies` list prefixed by a `$` will impact the cache fingerprint of _all_ tasks.
Expand Down Expand Up @@ -127,7 +127,7 @@ You can now control `turbo`'s [cache fingerprinting (a.k.a. hashing)](https://tu

Note: In most monorepos, you don't often use environment variables in shared packages, but mostly in applications. Thus, to get higher cache hit rates, you should only include environment variables in the app-specific tasks where they are used/inlined.

For more information, read the [caching and hashing documentation](https://turborepo.org/docs/features/caching).
For more information, read the [caching and hashing documentation](https://turborepo.org/docs/core-concepts/caching).

## Partial Yarn v2/v3 support

Expand Down
2 changes: 1 addition & 1 deletion docs/pages/blog/turbo-1-2-0.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ turbo run test --filter={./apps/web}[HEAD^1]^...

would tell `turbo` to ensure dependencies are built and to run the `test` script in all of the local dependencies of the app located in `./apps/web`, not including that app itself, if the app has changed since HEAD^1.

For more details and examples, refer to the new [filtering documentation](/docs/features/filtering).
For more details and examples, refer to the new [filtering documentation](/docs/core-concepts/filtering).

## Debug and Automate with `--dry-run`

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import Callout from "../../../components/callout";
import HeartIcon from "@heroicons/react/solid/HeartIcon";

<Callout type="error">
`--scope` is deprecated in `1.2.x`. Please use [`--filter`](/docs/features/filtering) instead.
`--scope` is deprecated in `1.2.x`. Please use [`--filter`](/docs/core-concepts/filtering) instead.
</Callout>

# Scoped Tasks
Expand Down
8 changes: 4 additions & 4 deletions docs/pages/docs/faq.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ description: Frequently asked questions about Turborepo.

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

No. [Remote Caching](./features/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.
No. [Remote Caching](./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.

## Does Turborepo / Remote Caching store my source code?

No. Turborepo does not store source code. Without [Remote Caching](./features/remote-caching), no code ever leaves your machine—it will only cache artifacts to local disk.
No. Turborepo does not store source code. Without [Remote Caching](./core-concepts/remote-caching), no code ever leaves your machine—it will only cache artifacts to local disk.

With Turborepo's Remote Caching, you are responsible for configuring cache behavior and should only set up Turborepo to cache compiled artifacts. Please be aware that Turborepo treats all logs as artifacts and so these _will_ be stored along with other cache artifacts.

Expand All @@ -21,15 +21,15 @@ No. Turborepo is an open source project and is not tied to any specific hosting

## Can I use Turborepo with a different Remote Cache provider other than Vercel?

Yes. As long as the [Remote Cache](./features/remote-caching) provider you choose supports the same API, you can use Turborepo with it.
Yes. As long as the [Remote Cache](./core-concepts/remote-caching) provider you choose supports the same API, you can use Turborepo with it.

## Does Turborepo collect any personally identifiable information?

Due to the nature of Turborepo's functionality, no personal information is gathered when the open source binary is run locally. All cached artifacts are stored on your machine by default. Further, no log in information or contact details are collected by the `turbo` CLI, so Turborepo will never have access to any personally identifiable information. Thus, for any data privacy questions and concerns please refer to [Turborepo's Privacy Policy](https://turborepo.org/privacy).

## Does Turborepo collect any personally identifiable information when using Remote Caching?

When [Remote Caching](./features/remote-caching) is enabled, by default Turbo will utilize your Vercel account to cache artifacts in the cloud. Thus, for any data privacy questions and concerns, please refer to [Turborepo's Privacy Policy](https://turborepo.org/privacy) and [Vercel's Privacy Policy](https://vercel.com/legal/privacy-policy). If you use a different Remote Cache provider, please refer to the provider's privacy policy.
When [Remote Caching](./core-concepts/remote-caching) is enabled, by default Turbo will utilize your Vercel account to cache artifacts in the cloud. Thus, for any data privacy questions and concerns, please refer to [Turborepo's Privacy Policy](https://turborepo.org/privacy) and [Vercel's Privacy Policy](https://vercel.com/legal/privacy-policy). If you use a different Remote Cache provider, please refer to the provider's privacy policy.

## How can I retain Fast Refresh in my Turborepo when using multiple Next.js applications?

Expand Down
4 changes: 2 additions & 2 deletions docs/pages/docs/getting-started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,12 @@ Your pipeline both defines the way in which your NPM `package.json` scripts rela

In the above example, the `build` and `test` tasks are dependent on their packages `dependencies` and `devDependencies` being built first, this is denoted with the `^` prefix.

For each script in each workspace's `package.json`, Turborepo will cache files outputted to `dist/**` and `build/**` folders relative to each packages's `package.json` by default if an override isn't added. Using the [`outputs`](./features/caching#configuring-cache-outputs-1) array allows you to override the default cache folders,
For each script in each workspace's `package.json`, Turborepo will cache files outputted to `dist/**` and `build/**` folders relative to each packages's `package.json` by default if an override isn't added. Using the [`outputs`](./core-concepts/caching#configuring-cache-outputs-1) array allows you to override the default cache folders,
like in the example above, where the `.next/**` folder is selected to be the default cache outputs folder for the `build` task for each package. Turborepo will automatically record and cache logs to `.turbo/turbo-<script>.log` for you, so you don't ever need to specify that in the `outputs` array.

Finally, the `dev` task has its caching disabled using the `cache` key with a value of `false`.

See the [`Pipelines`](./features/pipelines) documentation for more details on how to configure your pipeline.
See the [`Pipelines`](./core-concepts/pipelines) documentation for more details on how to configure your pipeline.

### Edit `.gitignore`

Expand Down
4 changes: 2 additions & 2 deletions docs/pages/docs/guides/migrate-from-lerna.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ Lerna is a monorepo task runner and NPM workspace implementation. Both Turborepo

### Caching

However, unlike Turborepo, Lerna has no ability to [cache prior work](../features/caching) or [intelligently schedule tasks (i.e. create pipelines)](../features/pipelines).
However, unlike Turborepo, Lerna has no ability to [cache prior work](../core-concepts/caching) or [intelligently schedule tasks (i.e. create pipelines)](../core-concepts/pipelines).

### Task Scheduling

Turborepo's task scheduler is more powerful than Lerna's (which can only schedule one task at a time) thanks to [Turborepo pipelines](../features/pipelines). Turborepo reduces idle CPUs, saves compute resource, and collapse waterfalls—which ultimately results in faster overall builds.
Turborepo's task scheduler is more powerful than Lerna's (which can only schedule one task at a time) thanks to [Turborepo pipelines](../core-concepts/pipelines). Turborepo reduces idle CPUs, saves compute resource, and collapse waterfalls—which ultimately results in faster overall builds.

Let's look at an example. Imagine you have two packages A and B each with 3 tasks `build`, `test`, and `bundle`, where A depends on B being built....

Expand Down
2 changes: 1 addition & 1 deletion docs/pages/docs/meta.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"index": "Introduction",
"getting-started": "Getting Started",
"features": "Core Concepts",
"core-concepts": "Core Concepts",
"ci": "CI Recipes",
"guides": "Guides",
"reference": "API Reference",
Expand Down
12 changes: 6 additions & 6 deletions docs/pages/docs/reference/command-line-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ turbo run build --cwd=./somewhere/else
#### `--deps`

<Callout type="error">
`--deps` is deprecated in `1.2.x`. Please use [`--filter`](/docs/features/filtering#include-dependents-of-matched-packages) instead.
`--deps` is deprecated in `1.2.x`. Please use [`--filter`](/docs/core-concepts/filtering#include-dependents-of-matched-packages) instead.
</Callout>

Defaults to `true`. Include dependent packages/apps consumers in the execution.
Expand Down Expand Up @@ -161,7 +161,7 @@ Multiple filters can be combined to select distinct sets of targets. Additionall
can also exclude targets. A target that matches any filter and is not explicitly excluded will
be in the final entrypoint selection.

For more detailed information about the `--filter` flag and filtering, refer to the [dedicated page in our documentation](/docs/features/filtering)
For more detailed information about the `--filter` flag and filtering, refer to the [dedicated page in our documentation](/docs/core-concepts/filtering)

```sh
turbo run build --filter=my-pkg
Expand Down Expand Up @@ -245,7 +245,7 @@ Just a quick overview.
#### `--include-dependencies`

<Callout type="error">
`--include-dependencies` is deprecated in `1.2.x`. Please use [`--filter`](/docs/features/filtering#include-dependencies-of-matched-packages) instead.
`--include-dependencies` is deprecated in `1.2.x`. Please use [`--filter`](/docs/core-concepts/filtering#include-dependencies-of-matched-packages) instead.
</Callout>

Default `false`. When `true`, `turbo` will add any packages that the packages in the current execution scope _depend_ on (i.e. those declared in `dependencies` or `devDependencies`).
Expand Down Expand Up @@ -324,7 +324,7 @@ The same behavior can also be set via the `TURBO_REMOTE_ONLY=true` environment v
#### `--scope`

<Callout type="error">
`--scope` is deprecated in `1.2.x`. Please use [`--filter`](/docs/features/filtering#filter-by-package) instead.
`--scope` is deprecated in `1.2.x`. Please use [`--filter`](/docs/core-concepts/filtering#filter-by-package) instead.
</Callout>

`type: string[]`
Expand All @@ -349,7 +349,7 @@ turbo run build --serial
#### `--since`

<Callout type="error">
`--since` is deprecated in `1.2.x`. Please use [`--filter`](/docs/features/filtering#filter-by-changed-packages) instead.
`--since` is deprecated in `1.2.x`. Please use [`--filter`](/docs/core-concepts/filtering#filter-by-changed-packages) instead.
</Callout>

Filter execution based on which packages have changed since a merge-base.
Expand Down Expand Up @@ -573,7 +573,7 @@ Logs you out of your Vercel account.

## `turbo link`

Link the current directory to Remote Cache scope. The selected owner (either a user or and organization) will be able to share [cache artifacts](../features/caching) through [Remote Caching](../features/remote-caching).
Link the current directory to Remote Cache scope. The selected owner (either a user or and organization) will be able to share [cache artifacts](../core-concepts/caching) through [Remote Caching](../core-concepts/remote-caching).
You should run this command from the root of your monorepo.

### Options
Expand Down
2 changes: 1 addition & 1 deletion docs/pages/docs/reference/configuration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ You can configure the behavior of `turbo` by adding a `turbo.json` file in your

`type: string`

Defaults to `origin/master`. The base branch or your git repository. Git is used by `turbo` in its [hashing algorithm](../features/caching#hashing-1) and [`--since` CLI flag](./command-line-reference#--since-1).
Defaults to `origin/master`. The base branch or your git repository. Git is used by `turbo` in its [hashing algorithm](../core-concepts/caching#hashing-1) and [`--since` CLI flag](./command-line-reference#--since-1).

## `globalDependencies`

Expand Down
12 changes: 6 additions & 6 deletions docs/pages/docs/troubleshooting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,17 @@ This guide aims to help you debug issues with your Turborepo builds and configur

- Is any source code being generated during the build that isn't checked into git?
- This would change the fingerprint Turborepo uses to store build outputs.
- Are [cache outputs properly specified](./features/caching#configuring-cache-outputs) in your Turborepo [pipeline](./features/pipelines#defining-a-pipeline)?
- Pipeline settings are not inherited or merged, so they need to be re-specified in [package-specific tasks](./features/pipelines#implicit-dependencies-and-specific-package-tasks) (e.g. `web#build` does **not** inherit pipeline settings from `build`).
- [Are relevant inlined environment variables accounted for?](./features/caching#alter-caching-based-on-environment-variables-and-files)
- Are [cache outputs properly specified](./core-concepts/caching#configuring-cache-outputs) in your Turborepo [pipeline](./core-concepts/pipelines#defining-a-pipeline)?
- Pipeline settings are not inherited or merged, so they need to be re-specified in [package-specific tasks](./core-concepts/pipelines#implicit-dependencies-and-specific-package-tasks) (e.g. `web#build` does **not** inherit pipeline settings from `build`).
- [Are relevant inlined environment variables accounted for?](./core-concepts/caching#alter-caching-based-on-environment-variables-and-files)
- To verify, run `turbo` in verbose mode by adding `-vvv` to `turbo run <task>` and look at which environment variables are included in the hashes.

## I'm seeing cache hits, but my build is broken

- Are [cache outputs properly specified](./features/caching#configuring-cache-outputs) in your Turborepo [pipeline](./features/pipelines#defining-a-pipeline)?
- Pipeline settings are not inherited or merged, so they need to be re-specified in [package-specific tasks](./features/pipelines#implicit-dependencies-and-specific-package-tasks) (e.g. `web#build` does **not** inherit pipeline settings from `build`).
- Are [cache outputs properly specified](./core-concepts/caching#configuring-cache-outputs) in your Turborepo [pipeline](./core-concepts/pipelines#defining-a-pipeline)?
- Pipeline settings are not inherited or merged, so they need to be re-specified in [package-specific tasks](./core-concepts/pipelines#implicit-dependencies-and-specific-package-tasks) (e.g. `web#build` does **not** inherit pipeline settings from `build`).

## My build is caching the wrong environment variables

- [Are relevant inlined environment variables accounted for?](./features/caching#alter-caching-based-on-environment-variables-and-files)
- [Are relevant inlined environment variables accounted for?](./core-concepts/caching#alter-caching-based-on-environment-variables-and-files)
- To verify, run `turbo` in verbose mode by adding `-vvv` to `turbo run <task>` and look at which environment variables are included in the hashes.
10 changes: 5 additions & 5 deletions examples/basic/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ yarn run dev

### Remote Caching

Turborepo can use a technique known as [Remote Caching (Beta)](https://turborepo.org/docs/features/remote-caching) to share cache artifacts across machines, enabling you to share build caches with your team and CI/CD pipelines.
Turborepo can use a technique known as [Remote Caching (Beta)](https://turborepo.org/docs/core-concepts/remote-caching) to share cache artifacts across machines, enabling you to share build caches with your team and CI/CD pipelines.

By default, Turborepo will cache locally. To enable Remote Caching (Beta) you will need an account with Vercel. If you don't have an account you can [create one](https://vercel.com/signup), then enter the following commands:

Expand All @@ -69,9 +69,9 @@ npx turbo link

Learn more about the power of Turborepo:

- [Pipelines](https://turborepo.org/docs/features/pipelines)
- [Caching](https://turborepo.org/docs/features/caching)
- [Remote Caching (Beta)](https://turborepo.org/docs/features/remote-caching)
- [Scoped Tasks](https://turborepo.org/docs/features/scopes)
- [Pipelines](https://turborepo.org/docs/core-concepts/pipelines)
- [Caching](https://turborepo.org/docs/core-concepts/caching)
- [Remote Caching (Beta)](https://turborepo.org/docs/core-concepts/remote-caching)
- [Scoped Tasks](https://turborepo.org/docs/core-concepts/scopes)
- [Configuration Options](https://turborepo.org/docs/reference/configuration)
- [CLI Usage](https://turborepo.org/docs/reference/command-line-reference)
10 changes: 5 additions & 5 deletions examples/with-pnpm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ pnpm run dev

### Remote Caching

Turborepo can use a technique known as [Remote Caching (Beta)](https://turborepo.org/docs/features/remote-caching) to share cache artifacts across machines, enabling you to share build caches with your team and CI/CD pipelines.
Turborepo can use a technique known as [Remote Caching (Beta)](https://turborepo.org/docs/core-concepts/remote-caching) to share cache artifacts across machines, enabling you to share build caches with your team and CI/CD pipelines.

By default, Turborepo will cache locally. To enable Remote Caching (Beta) you will need an account with Vercel. If you don't have an account you can [create one](https://vercel.com/signup), then enter the following commands:

Expand All @@ -69,9 +69,9 @@ npx turbo link

Learn more about the power of Turborepo:

- [Pipelines](https://turborepo.org/docs/features/pipelines)
- [Caching](https://turborepo.org/docs/features/caching)
- [Remote Caching (Beta)](https://turborepo.org/docs/features/remote-caching)
- [Scoped Tasks](https://turborepo.org/docs/features/scopes)
- [Pipelines](https://turborepo.org/docs/core-concepts/pipelines)
- [Caching](https://turborepo.org/docs/core-concepts/caching)
- [Remote Caching (Beta)](https://turborepo.org/docs/core-concepts/remote-caching)
- [Scoped Tasks](https://turborepo.org/docs/core-concepts/scopes)
- [Configuration Options](https://turborepo.org/docs/reference/configuration)
- [CLI Usage](https://turborepo.org/docs/reference/command-line-reference)
Loading

0 comments on commit f389841

Please sign in to comment.