Not able to build maven project using Maven configured with Jenkins

4.1k Views Asked by At

Building in workspace C:\Users\5078722.jenkins\jobs\TempExp\workspace

 > C:\Program Files (x86)\Git\bin\git.exe rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > C:\Program Files (x86)\Git\bin\git.exe config remote.origin.url 
Fetching upstream changes from 
 > C:\Program Files (x86)\Git\bin\git.exe --version # timeout=10
using .gitcredentials to set credentials
 > C:\Program Files (x86)\Git\bin\git.exe config --local credential.helper store --file=\"C:\tomcat7\temp\git781129730469989565.credentials\" # timeout=10
Setting http proxy: internet.proxy.fedex.com:3128
 > C:\Program Files (x86)\Git\bin\git.exe -c core.askpass=true fetch --tags --progress https://github.com/sharath502/MavenDemo.git +refs/heads/*:refs/remotes/origin/*
 > C:\Program Files (x86)\Git\bin\git.exe config --local --remove-section credential # timeout=10
 > C:\Program Files (x86)\Git\bin\git.exe rev-parse "refs/remotes/origin/master^{commit}" # timeout=10
 > C:\Program Files (x86)\Git\bin\git.exe rev-parse "refs/remotes/origin/origin/master^{commit}" # timeout=10
Checking out Revision acc2095cad14f15049ddb2c807a9200c530a0ed5 (refs/remotes/origin/master)
 > C:\Program Files (x86)\Git\bin\git.exe config core.sparsecheckout # timeout=10
 > C:\Program Files (x86)\Git\bin\git.exe checkout -f acc2095cad14f15049ddb2c807a9200c530a0ed5
 > C:\Program Files (x86)\Git\bin\git.exe rev-list acc2095cad14f15049ddb2c807a9200c530a0ed5 # timeout=10
FATAL: Couldn’t find any executable in C:\maven
Build step 'Invoke top-level Maven targets' marked build as failure
Finished: FAILURE

I have installed maven on my local machine and the maven --version command works well.

1

There are 1 best solutions below

3
On BEST ANSWER

Did you declare your Maven installation in the global settings?

If not, please add your Maven installation ("My Maven install" --> C:\Maven).

Next, please update your Maven project and select the relevant Maven installation.