![](/img/trans.png)
[英]Running "haxe build.hxml" command gives me "permission denied" error
[英]Where's the HXML docs?
得到它了! 以下是Haxe编译器的HXML /命令行选项的完整列表
你有没有尝试过:
haxe --help
据我所知,.hxml文件只是传递命令行参数的一种方便方法。
对于高级用法和一些提示,这是Andy Li的一篇很棒的文章( https://stackoverflow.com/users/267998/andy-li )
http://blog.onthewings.net/2013/03/04/hxml-tricks-every-haxe-user-should-know/
以hash(#)开头的行不会被视为参数。
#Yay! Comments!
成功编译后,使用-cmd
运行任何命令行。
#C++
-cpp bin
-main Test
-cmd ./bin/Test
#Flash
-swf Test.swf
-main Test
-cmd path/to/FlashDebugger Test.swf
#Neko
-neko Test.n
-main Test
-cmd neko Test.n
对于Neko目标,有一个特殊的快捷方式来构建和运行-x Test
。
附加参数也有效,例如,如果要构建调试版本
haxe project.hxml -debug
使用--next
分隔不同的目标/配置构建。 使用--each
将参数应用于--each
中的每个构建。
#lib will be used in every '--next' build
-lib jQueryExtern
--each
#build MainPage
-js script/MainPage.js
-main MainPage
--next
#build ContactPage
-js script/ContactPage.js
-main ContactPage
#build AlbumPage
--next
-js script/AlbumPage.js
-main AlbumPage
您可以通过为每个配置创建一个hxml来进一步分离不同的构建配置。
client.hxml:
-main Client
-js client.js
server.hxml:
-main Server
-neko server.n
all.hxml:
client.hxml
--next
server.hxml
构建两者: haxe all.hxml
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.