diff --git a/project.hxp b/project.hxp index 624287b8e..5f9130c35 100644 --- a/project.hxp +++ b/project.hxp @@ -1470,8 +1470,8 @@ class Project extends HXProject function clearAssets():Void { - // We don't want the haxe compilation server deleting our assets, do we? - if (isDisplay()) return; + // Don't run on non-build commands. + if (!isBuild()) return; var exportPath:Null = app.path ?? ""; @@ -1739,6 +1739,11 @@ class Project extends HXProject return this.command == "clean"; } + public function isBuild():Bool + { + return this.command == "test" || this.command == "build"; + } + public function isDebug():Bool { return this.debug;