-
-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do a "grunt build" before generating a WAR file #28
Comments
You're right... That was one of my main ideas at the beginning of the project, and I totally forgot it!!! So thanks for the bug report :-) I don't think the yeoman-maven-plugin will help a lot, but it's worth checking out. My idea at the moment (but I haven't tried it for real!) would be to run a "grunt build" by running something like the Maven Exec plugin: http://mojo.codehaus.org/exec-maven-plugin/usage.html |
This project https://github.com/trecloux/yeoman-maven-samples show an example base on "yeoman-maven-plugin". The "yeoman-maven-plugin" simply execute "npm install", "bower install" and "grunt (test/)build". The files structure is quiet different, but simply to mimic. Extract all CSS, SASS, JS, images, ... from webapp to a root subfolder to avoid to overwrite them or duplicate them. (i'm french, sorry or the English, i know you too ;-)) |
Yes, that's exactly what I want to do, run the bower/grunt commands from Maven, with the JHipster file structure. I'm not sure it's a good idea to depend on yeoman-maven-plugin, as it's so simple we can just configure the maven exec plugin to do the same thing. But it's worth trying both options before deciding. |
I did exactly that using maven exec plugin and two different scripts for unix/win. https://github.com/philippd/angular-spring-webmvc/blob/master/pom.xml |
If @philippd solution already works, and doesn't need a plugin, I'll go for it! The only downside is the build scripts that need to be at the root of the project, can't those commands be run straight from the exec plugin? |
Use jhipster-dependencies
Use jhipster-dependencies
All nodejs server et jetty server work fine. But i wondering how to have all files generated
by "grunt build" in the WAR when doing a "mvn package".
I see the yeoman-maven-plugin to launch yo command. May be it's possible to register a new task to generate minify, uglify, ... file and to inject it in the webapp ?
The text was updated successfully, but these errors were encountered: