@@ -0,0 +1,16 @@
|
||||
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;
|
||||
}
|
||||
},
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user