diff --git a/jake/jake.d.ts b/jake/jake.d.ts index 1812b818b7..95614374cc 100644 --- a/jake/jake.d.ts +++ b/jake/jake.d.ts @@ -40,6 +40,16 @@ declare function fail(...err:any[]): void; */ declare function file(name:string, prereqs?:string[], action?:()=>void, opts?:jake.FileTaskOptions): jake.FileTask; +/** + * Creates Jake FileTask from regex patterns + * @name name/pattern of the Task + * @param source calculated from the name pattern + * @param prereqs Prerequisites to be run before this task + * @param action The action to perform for this task + * @param opts Perform this task asynchronously. If you flag a task with this option, you must call the global `complete` method inside the task's action, for execution to proceed to the next task. + */ +declare function rule(pattern: RegExp, source: string | { (name: string): string; }, prereqs?: string[], action?: () => void, opts?: jake.TaskOptions): void; + /** * Creates a namespace which allows logical grouping of tasks, and prevents name-collisions with task-names. Namespaces can be nested inside of other namespaces. * @param name The name of the namespace @@ -185,6 +195,11 @@ declare module jake{ * @default false */ async?: boolean; + + /** + * number of parllel async tasks + */ + parallelLimit?: number; } /**