Skip to content

Commit

Permalink
Pass additional -... params from build.sh to mvn.
Browse files Browse the repository at this point in the history
  • Loading branch information
OndraZizka authored and bstansberry committed Nov 10, 2011
1 parent 2dd51d5 commit c7e2071
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,12 @@ main() {
# Add smoke integration test directives before calling maven.
TESTS=$SMOKE_TESTS
MVN_GOAL="";
ADDIT_PARAMS="";
# For each parameter, check for testsuite directives.
for param in $@ ; do
case $param in
-DallTests) TESTS=$ALL_TESTS ;;
-*) ;;
-*) ADDIT_PARAMS="$ADDIT_PARAMS $param";;
clean) MVN_GOAL="$MVN_GOAL$param ";;
test) MVN_GOAL="$MVN_GOAL$param ";;
install) MVN_GOAL="$MVN_GOAL$param ";;
Expand All @@ -181,13 +182,13 @@ main() {
# Export some stuff for maven.
export MVN MAVEN_HOME MVN_OPTS MVN_GOAL

echo "$MVN $MVN_OPTIONS $MVN_GOAL"
echo "$MVN $MVN_OPTIONS $MVN_GOAL $ADDIT_PARAMS"

# Execute in debug mode, or simply execute.
if [ "x$MVN_DEBUG" != "x" ]; then
/bin/sh -x $MVN $MVN_OPTIONS $MVN_GOAL
/bin/sh -x $MVN $MVN_OPTIONS $MVN_GOAL $ADDIT_PARAMS
else
exec $MVN $MVN_OPTIONS $MVN_GOAL
exec $MVN $MVN_OPTIONS $MVN_GOAL $ADDIT_PARAMS
fi
}

Expand Down

0 comments on commit c7e2071

Please sign in to comment.