Files
gulp-haxetool/src/task/impl/proto.ts
T
shmyga 441b800b18
test / test (push) Successful in 2m35s
feat: add task module
2026-11-07 00:18:03 +03:00

17 lines
492 B
TypeScript

import { Haxe } from "../../impl/haxe";
import { TaskCompilerImpl, type TaskBundle } from "../core";
export class ProtoTaskCompiler extends TaskCompilerImpl {
compile(): TaskBundle {
return {
"protohx:generate": async () => {
const haxe = new Haxe(this.config.haxe);
const result = await haxe.haxelib(["run", "protohx", "generate", "protohx.json"]);
if (result.stdout.indexOf("FAIL") > -1) {
throw result.stdout;
}
},
};
}
}