Create skinny War file using Maven in Mavenized Grails

65 views Asked by At

How to create a skinny war file in mavenized grails project using maven-grails plugin? Skinny war can be created using grails command through "grails war --nojars". The grails maven plugin through which grails war can be created using mvn grails:war command. But, this creates the usual fat war file not the skinny one. There is no way to pass parameter "nojars" to mvn as it gets passed to mvn and not to grails plugin. Also, on reading the source code of the plugin it seems to take value for grails.cli.args system property to get any parameter passed while invoking grails war internally.

So, Is there a way this can be done.

1

There are 1 answers

0
Sumit Shrestha On BEST ANSWER

I was able to fix this issue. It can be done by

mvn   grails:war -Dgrails.cli.args="--nojars"