export type Task = {
    /**
     * The command to run for the task.
     */
    command: string;
    /**
     * The working directory for the task, relative to the package root (not workspace root).
     */
    cwd?: string;
    /**
     * Dependencies of this task. Use `package-name#task-name` to refer to tasks in other packages.
     */
    dependsOn?: Array<string>;
} & ({
    /**
     * Whether to cache the task
     */
    cache?: true;
    /**
     * Environment variable names to be fingerprinted and passed to the task.
     */
    env?: Array<string>;
    /**
     * Environment variable names to be passed to the task without fingerprinting.
     */
    untrackedEnv?: Array<string>;
    /**
     * Files to include in the cache fingerprint.
     *
     * - Omitted: automatically tracks which files the task reads
     * - `[]` (empty): disables file tracking entirely
     * - Glob patterns (e.g. `"src/**"`) select specific files
     * - `{auto: true}` enables automatic file tracking
     * - Negative patterns (e.g. `"!dist/**"`) exclude matched files
     *
     * Patterns are relative to the package directory.
     */
    input?: Array<string | {
        /**
         * Automatically track which files the task reads
         */
        auto: boolean;
    }>;
} | {
    /**
     * Whether to cache the task
     */
    cache: false;
});
export type UserGlobalCacheConfig = boolean | {
    /**
     * Enable caching for package.json scripts not defined in the `tasks` map.
     *
     * When `false`, package.json scripts will not be cached.
     * When `true`, package.json scripts will be cached with default settings.
     *
     * Default: `false`
     */
    scripts?: boolean;
    /**
     * Global cache kill switch for task entries.
     *
     * When `false`, overrides all tasks to disable caching, even tasks with `cache: true`.
     * When `true`, respects each task's individual `cache` setting
     * (each task's `cache` defaults to `true` if omitted).
     *
     * Default: `true`
     */
    tasks?: boolean;
};
export type RunConfig = {
    /**
     * Root-level cache configuration.
     *
     * This option can only be set in the workspace root's config file.
     * Setting it in a package's config will result in an error.
     */
    cache?: UserGlobalCacheConfig;
    /**
     * Task definitions
     */
    tasks?: {
        [key in string]?: Task;
    };
    /**
     * Whether to automatically run `preX`/`postX` package.json scripts as
     * lifecycle hooks when script `X` is executed.
     *
     * When `true` (the default), running script `test` will automatically
     * run `pretest` before and `posttest` after, if they exist.
     *
     * This option can only be set in the workspace root's config file.
     * Setting it in a package's config will result in an error.
     */
    enablePrePostScripts?: boolean;
};
