diff --git a/packages/turbo-types/schemas/schema.json b/packages/turbo-types/schemas/schema.json index 4d772ca14f6ce..0f28bb4c48049 100644 --- a/packages/turbo-types/schemas/schema.json +++ b/packages/turbo-types/schemas/schema.json @@ -164,6 +164,11 @@ "type": "boolean", "description": "Mark a task as interactive allowing it to receive input from stdin. Interactive tasks must be marked with \"cache\": false as the input they receive from stdin can change the outcome of the task.\n\nDocumentation: https://turbo.build/repo/docs/reference/configuration#interactive", "default": false + }, + "interruptible": { + "type": "boolean", + "description": "Label a persistent task as interruptible to allow it to be restarted by `turbo watch`. `turbo watch` watches for changes to your packages and automatically restarts tasks that are affected. However, if a task is persistent, it will not be restarted by default. To enable restarting persistent tasks, set `interruptible` to true.\n\nDocumentation: https://turbo.build/repo/docs/reference/configuration#interruptible", + "default": false } }, "additionalProperties": false diff --git a/packages/turbo-types/schemas/schema.v2.json b/packages/turbo-types/schemas/schema.v2.json index 4d772ca14f6ce..0f28bb4c48049 100644 --- a/packages/turbo-types/schemas/schema.v2.json +++ b/packages/turbo-types/schemas/schema.v2.json @@ -164,6 +164,11 @@ "type": "boolean", "description": "Mark a task as interactive allowing it to receive input from stdin. Interactive tasks must be marked with \"cache\": false as the input they receive from stdin can change the outcome of the task.\n\nDocumentation: https://turbo.build/repo/docs/reference/configuration#interactive", "default": false + }, + "interruptible": { + "type": "boolean", + "description": "Label a persistent task as interruptible to allow it to be restarted by `turbo watch`. `turbo watch` watches for changes to your packages and automatically restarts tasks that are affected. However, if a task is persistent, it will not be restarted by default. To enable restarting persistent tasks, set `interruptible` to true.\n\nDocumentation: https://turbo.build/repo/docs/reference/configuration#interruptible", + "default": false } }, "additionalProperties": false diff --git a/packages/turbo-types/src/types/config-v2.ts b/packages/turbo-types/src/types/config-v2.ts index 8b6206622f5e0..f162e7e174a08 100644 --- a/packages/turbo-types/src/types/config-v2.ts +++ b/packages/turbo-types/src/types/config-v2.ts @@ -282,6 +282,19 @@ export interface Pipeline { * @defaultValue `false` */ interactive?: boolean; + + /** + * Label a persistent task as interruptible to allow it to be restarted by `turbo watch`. + * `turbo watch` watches for changes to your packages and automatically + * restarts tasks that are affected. However, if a task is persistent, it will + * not be restarted by default. To enable restarting persistent tasks, set + * `interruptible` to true. + * + * Documentation: https://turbo.build/repo/docs/reference/configuration#interruptible + * + * @defaultValue `false` + */ + interruptible?: boolean; } export interface RemoteCache {