fix(core): update

This commit is contained in:
2020-03-15 16:36:25 +00:00
parent 1e8ab2d7a2
commit b2dbc9160b
5 changed files with 274 additions and 370 deletions

View File

@ -7,13 +7,16 @@ export interface IPreTaskFunction {
}
export class PreTask {
public description: string;
public preTaskFunction: IPreTaskFunction;
constructor(preTaskFunctionArg: IPreTaskFunction) {
constructor(descriptionArg: string, preTaskFunctionArg: IPreTaskFunction) {
this.description = descriptionArg;
this.preTaskFunction = preTaskFunctionArg;
}
public async run () {
console.log(`::__PRETASK: ${this.description}`);
await this.preTaskFunction(new TapTools(null));
}
}

View File

@ -53,8 +53,8 @@ export class Tap {
return localTest;
}
public preTask (functionArg: IPreTaskFunction) {
this._tapPreTasks.push(new PreTask(functionArg));
public preTask (descriptionArg: string, functionArg: IPreTaskFunction) {
this._tapPreTasks.push(new PreTask(descriptionArg, functionArg));
}
/**