We help IT Professionals succeed at work.

Check out our new AWS podcast with Certified Expert, Phil Phillips! Listen to "How to Execute a Seamless AWS Migration" on EE or on your favorite podcast platform. Listen Now

x

Need to write a batch file to build project using maven

Medium Priority
336 Views
Last Modified: 2012-05-11
I am building and Deploying a multi module project. I need to write a batch file to build and deploy the project.
I am trying something like followng in my bat file:

cd "C:\Projects\java\com.radsdk.protocols"
mvn install
cd "C:\Projects\java\com.radsdk.framework"
mvn install

But I am not able to execute this. It installs one module but do nothing for the another module. I am new to Maven. Is there any better way to bulid and deploy application using maven?
Comment
Watch Question

CERTIFIED EXPERT
Top Expert 2016
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION
Amitkumar PSr. Consultant
CERTIFIED EXPERT

Commented:
MeenuNagpal,

Also try the following by adding it in your batch file.

pushd "C:\Projects\java\com.radsdk.protocols"
mvn install
popd
pushd "C:\Projects\java\com.radsdk.framework"
mvn install
popd

Author

Commented:
This worked perfectly fine for me
Thanks
CERTIFIED EXPERT
Top Expert 2016

Commented:
:)
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.