@@ -67,51 +67,47 @@ export type Task = {
6767 }
6868) ;
6969
70- export type UserGlobalCacheConfig =
71- | boolean
72- | {
73- /**
74- * Enable caching for package.json scripts not defined in the `tasks` map.
75- *
76- * When `false`, package.json scripts will not be cached.
77- * When `true`, package.json scripts will be cached with default settings.
78- *
79- * Default: `false`
80- */
81- scripts ?: boolean ;
82- /**
83- * Global cache kill switch for task entries.
84- *
85- * When `false`, overrides all tasks to disable caching, even tasks with `cache: true`.
86- * When `true`, respects each task's individual `cache` setting
87- * (each task's `cache` defaults to `true` if omitted).
88- *
89- * Default: `true`
90- */
91- tasks ?: boolean ;
92- } ;
70+ export type UserGlobalCacheConfig = boolean | {
71+ /**
72+ * Enable caching for package.json scripts not defined in the `tasks` map.
73+ *
74+ * When `false`, package.json scripts will not be cached.
75+ * When `true`, package.json scripts will be cached with default settings.
76+ *
77+ * Default: `false`
78+ */
79+ scripts ?: boolean ,
80+ /**
81+ * Global cache kill switch for task entries.
82+ *
83+ * When `false`, overrides all tasks to disable caching, even tasks with `cache: true`.
84+ * When `true`, respects each task's individual `cache` setting
85+ * (each task's `cache` defaults to `true` if omitted).
86+ *
87+ * Default: `true`
88+ */
89+ tasks ?: boolean , } ;
9390
94- export type RunConfig = {
95- /**
96- * Root-level cache configuration.
97- *
98- * This option can only be set in the workspace root's config file.
99- * Setting it in a package's config will result in an error.
100- */
101- cache ?: UserGlobalCacheConfig ;
102- /**
103- * Task definitions
104- */
105- tasks ?: { [ key in string ] ?: Task } ;
106- /**
107- * Whether to automatically run `preX`/`postX` package.json scripts as
108- * lifecycle hooks when script `X` is executed.
109- *
110- * When `true` (the default), running script `test` will automatically
111- * run `pretest` before and `posttest` after, if they exist.
112- *
113- * This option can only be set in the workspace root's config file.
114- * Setting it in a package's config will result in an error.
115- */
116- enablePrePostScripts ?: boolean ;
117- } ;
91+ export type RunConfig = {
92+ /**
93+ * Root-level cache configuration.
94+ *
95+ * This option can only be set in the workspace root's config file.
96+ * Setting it in a package's config will result in an error.
97+ */
98+ cache ?: UserGlobalCacheConfig ,
99+ /**
100+ * Task definitions
101+ */
102+ tasks ?: { [ key in string ] ?: Task } ,
103+ /**
104+ * Whether to automatically run `preX`/`postX` package.json scripts as
105+ * lifecycle hooks when script `X` is executed.
106+ *
107+ * When `true` (the default), running script `test` will automatically
108+ * run `pretest` before and `posttest` after, if they exist.
109+ *
110+ * This option can only be set in the workspace root's config file.
111+ * Setting it in a package's config will result in an error.
112+ */
113+ enablePrePostScripts ?: boolean , } ;
0 commit comments