No commit activity in last 3 years
No release in over 3 years
Execute your complex maven commands faster with the shortened helper syntax. See the rdoc for more details and examples.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 2.0
~> 4.2
~> 3.2
 Project Readme

Maven Helper Script¶ ↑

<img src=“https://secure.travis-ci.org/benkiefer/maven-helper-script.png” /> <img src=“https://badge.fury.io/rb/maven-helper-script.svg” alt=“Gem Version” />

What is it?¶ ↑

A script to simplify how you execute Maven commands. For example, instead of:

mvn clean install -pl parent && mvn clean install -pl domain

You can do something like:

m ci p ci d

How?¶ ↑

All you need is a YAML file with contents like this:

modules:
  p: parent
  d: domain
commands:
  - clean
  - install
arguments:
  - -ff

Or you can supply a YAML file with your commands in a map, like this:

modules:
  p: parent
  d: domain
commands:
  c: clean
  i: install
  cd: clean deploy
arguments:
  - -ff

Additional Features¶ ↑

If you don’t want to define a mapping for your module, you can use it’s name.

m ci parent ci d

You can also create shorthand commands for various plugin phases. For example, executing “jetty:run” on your “web” module could be:

m jr web

if you provide a mapping file with either:

commands:
  jr: jetty:run

or:

commands:
  - jetty:run

All parameters passed into the helper script are applied to every execution. So you only need to flag a command like offline mode once:

m ci web ci parent -o

Including the optional “arguments:” mapping in your m.yml file allows you to apply arguments without typing them in the command line. The example YAML files above would trigger the “-ff” arg for maven.

Commands can be executed in any directory of your project, as long as there is an “m.yml” file in your project’s top-level directory.

How do I use it?¶ ↑

- Make sure you have ruby installed and on your path.
- In a command window, type "gem install maven-helper-script".
- Find one of your existing maven projects and put an "m.yml" file like the one above in the top-level directory.
- In a command window, "cd" to a directory in your project.
- Execute a command.

If you’re having trouble, take a look at the wiki or sample-mvn-project located within the project.