報(bào)錯(cuò)截圖及詳細(xì):
15:30:29[ERROR]The goal you specified requires a project to execute but there is no POM inthis directory (/data/workspace). Please verify you invoked Maven from thecorrect directory. -> [Help 1]
15:30:29[ERROR]
15:30:29[ERROR] Tosee the full stack trace of the errors, re-run Maven with the -e switch.
15:30:29[ERROR]Re-run Maven using the -X switch to enable full debug logging.
15:30:29[ERROR]
15:30:29[ERROR]For more information about the errors and possible solutions, please read thefollowing articles:
解決方法:
這里的報(bào)錯(cuò)财剖,分析了下江兢,發(fā)現(xiàn)jenkins拉下代碼來編譯,編譯不了宜咒,發(fā)現(xiàn)就是workspace下面沒有java代碼編譯需要的pom文件飒责,要將代碼路徑切換到有pom文件的地方赘娄,才可以mvn? install。
就是在jenkins上build上面--------調(diào)用shell宏蛉,在shell切換編譯路徑