开发者

Does it make sense to use ant build with a grails application?

If I understand correctly, the purpose of groovy and grails are to execute without (visible) compilation. Howe开发者_StackOverflow中文版ver, I have inherited some old grails code that I can't build any more.

I can see the advantages of having a build.xml file for special purposes, but, considering that the programming nature of Grails is to run on the fly, does it make, or did it ever make sense at one point, to use a build script?

A question from a rather newbie in Grails.

Thanks!

Luis


Grails is a high-productivity development framework that leverages best of breed Java based technologies to simplify web application development. The purpose is not to 'execute without visible compilation'.

One way Grails simplifies the development process is by providing canned build functionalities -- you are thing of 'grails run-app' when you talk about no visible compilation. But that command is only used in development, and it is strongly recommended you do not use it anywhere else. When you deploy, you want to run

grails -Dgrails.env=prod war

to generate a war file for a production environment. You are going to want to leverage the Grails build machinery to customize the build process for your purposes -- for example, you can write a build script to copy your war to a machine or deploy it.

Check out gant, which is a wrapper around ant, but groovy...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜