Ant MXMLC 任务具有任意源/lib 路径列表?
有谁知道如何将 mxmlc Flex Ant 任务与用户定义的源或库路径列表一起使用?
用户应该能够在 Ant 属性文件中定义源和/或库 (.swc) 路径的任意列表,并且构建文件可以在 mxmlc 任务中使用这些值。
有什么技巧(也许使用过滤/字符串替换)来使其工作吗?
Does anyone know of a way to use the mxmlc Flex Ant task with a user-defined list of source or library paths?
The user should be able to define an arbitrary list of source and/or library (.swc) paths in an Ant properties file and the build file can use these values in the mxmlc task.
Are there any tricks (maybe use filtering/string replacing) to get this working?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
不知道这是否有帮助,但您可以 在 Ant 中包含外部 XML构建文件:
我遇到了你的问题,寻找一种在外部文件中定义库(和源路径)定义的方法。循环遍历定义的属性列表对我来说似乎有点问题,因为您可能必须定义库路径列表以及列表中每个定义路径中的文件子列表。
似乎包含定义库和各种源路径的外部文件可能是更好且可扩展的方法。
Don't know if this helps, but you can include an external XML in your Ant build file:
I ran across your question, looking for a way to define the library (and source path) definitions in external files. Looping through a list of defined properties seems somewhat problematic to me, since you would possibly have to define a list of library paths as well as sub-lists of files in each defined path in the list.
Seems that including external files defining the library and various source paths might be a better and just as extensible way to go.
我这样做的方式是在外部mxmlc配置文件(例如flex-config.xml)中列出我的源路径、库路径等,我的或多或少通用的build.xml文件只是执行
Whereair.sdk.config点SDK 的默认配置 xml 和 app.config 是应用程序的自定义配置 xml。
They way I do it is list my source paths, library paths etc. in an external mxmlc configuration file (e.g. flex-config.xml), my more-or-less universal build.xml file just does
Where air.sdk.config points to the SDK's default config xml and app.config is the app's custom config xml.
我不知道是否可以从属性文件中执行此操作。
您可以在 Ant 脚本中使用它:
或者开发一些 Ant 模块来从属性文件中模拟它。
我不明白为什么你想让你的属性文件动态化,这通常是你的 build.xml 的作用,但是嘿:)
I don't know if it is possible to do it from a properties file.
You can use this in your Ant script:
Or maybe develop some Ant module to simulate this from your properties file.
I can't understand why you want to make your properties file dynamic, it is the role of your build.xml normally, but hey :)