Commit 74a2075 1 parent 966c118 commit 74a2075 Copy full SHA for 74a2075
File tree 1 file changed +19
-0
lines changed
docs/site/content/repo-docs/reference
1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -358,6 +358,8 @@ An allowlist of environment variables that should be made available to this task
358
358
359
359
A list of file glob patterns relative to the package's ` package.json ` to cache when the task is successfully completed.
360
360
361
+ See [ ` $TURBO_ROOT$ ` ] ( #turbo_root ) if output paths need to be relative to the repository root.
362
+
361
363
``` jsonc title="./turbo.json"
362
364
{
363
365
" tasks" : {
@@ -431,6 +433,23 @@ the special string `$TURBO_DEFAULT$` within the `inputs` array to restore `turbo
431
433
}
432
434
```
433
435
436
+ #### ` $TURBO_ROOT$ `
437
+
438
+ Tasks might reference a file that lies outside of their directory.
439
+
440
+ Starting a file glob with ` $TURBO_ROOT$ ` will change the glob to be relative to the root of the repository instead of the package directory.
441
+
442
+ ``` jsonc title="./turbo.json"
443
+ {
444
+ " tasks" : {
445
+ " check-types" : {
446
+ // Consider all Typescript files in `src/` and the root tsconfig.json as inputs
447
+ " inputs" : [" $TURBO_ROOT$/tsconfig.json" , " src/**/*.ts" ]
448
+ }
449
+ }
450
+ }
451
+ ```
452
+
434
453
### ` outputLogs `
435
454
436
455
Default: ` full `
You can’t perform that action at this time.
0 commit comments