[ERROR] No goals have been specified for this build. You must specify a valid lifecycle phase or a goal in the format : or :[:]:. Available lifecycle phases are: validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy, pre-clean, clean, post-clean, pre-site, site, post-site, site-deploy. -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/NoGoalSpecifiedException
Build step ‘Invoke top-level Maven targets’ marked build as failure
Finished: FAILURE
Pre Steps填充内容:
export moduleVer=`java -jar /home/jenkins/jk_home/deployHistory/aliImg.jar ci ce next`
echo "新版本=$moduleVer"
echo "$moduleVer" > impl/impl-ofce/ver.txt
sed -i "s/artifactId>.*<version>.*<\/version>/artifactId><version>${moduleVer}<\/version>/" impl/impl-ce/pom.xml
cd common;mvn install;cd ..;
cd api;mvn install;cd ..;
cd tool;mvn install;cd ..;
cd impl;mvn install;cd ..;
mvn compiler:compile;
mvn install;
并且Post Steps选择:
Run only if build succeeds
再次build就可以成功了