[ERROR] No plugin found for prefix ‘exec‘ in the current project and in the plugin groups [org.apach

在尝试使用Maven的exec命令时遇到了NoPluginFoundForPrefixException错误,即使更改了镜像源至阿里云也没有解决问题。最后,通过注释掉settings.xml中本地仓库的设置解决了这个问题,但具体原因未明。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

在用maven执行exec命令是出现以下报错

[ERROR] No plugin found for prefix 'exec' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehau
s.mojo] available from the repositories [local (D:\Program Files\maven-repository), alimaven (http://maven.aliyun.com/nexus/cont
ent/groups/public/)] -> [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/NoPluginFoundForPrefixException

网上找到的方法大多说把镜像的url改为阿里云的,但是我改了镜像也没有解决,还是要同样的报错。

最终解决方法

settings.xml里的本地仓库设置注释掉就可以了,但是原因不明。。。

<!-- <localRepository>D:\Program Files\maven-repository</localRepository> -->
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.5.3/maven-release-plugin-2.5.3.pom Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.5.3/maven-release-plugin-2.5.3.pom (11 kB at 1.0 MB/s) Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/release/maven-release/2.5.3/maven-release-2.5.3.pom Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/release/maven-release/2.5.3/maven-release-2.5.3.pom (5.0 kB at 502 kB/s) Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/27/maven-parent-27.pom Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/27/maven-parent-27.pom (41 kB at 3.7 MB/s) Downloading from central: https://repo.maven.apache.org/maven2/org/apache/apache/17/apache-17.pom Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/apache/17/apache-17.pom (16 kB at 1.5 MB/s) Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.5.3/maven-release-plugin-2.5.3.jar Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.5.3/maven-release-plugin-2.5.3.jar (53 kB at 4.1 MB/s) Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml Downloading from central: https://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml (14 kB at 1.3 MB/s) Downloaded from central: https://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml (21 kB at 764 kB/s) [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1.954 s [INFO] Finished at: 2025-07-09T06:18:06Z [INFO] ------------------------------------------------------------------------ [ERROR] No plugin found for prefix 'spring-boot' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (/root/.m2/repository), central (https://repo.maven.apache.org/maven2)] -> [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/NoPluginFoundForPrefixException root@srv771551:~/jeecg-boot# cd ../jeecgboot-vue3 -bash: cd: ../jeecgboot-vue3: No such file or directory root@srv771551:~/jeecg-boot# npm install npm run dev npm ERR! code ENOENT npm ERR! syscall open npm ERR! path /root/jeecg-boot/package.json npm ERR! errno -2 npm ERR! enoent ENOENT: no such file or directory, open '/root/jeecg-boot/package.json' npm ERR! enoent This is related to npm not being able to find a file. npm ERR! enoent npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2025-07-09T06_18_32_236Z-debug-0.log npm ERR! code ENOENT npm ERR! syscall open npm ERR! path /root/jeecg-boot/package.json npm ERR! errno -2 npm ERR! enoent ENOENT: no such file or directory, open '/root/jeecg-boot/package.json' npm ERR! enoent This is related to npm not being able to find a file. npm ERR! enoent npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2025-07-09T06_18_34_357Z-debug-0.log root@srv771551:~/jeecg-boot#
最新发布
07-10
评论 6
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

打孔猿

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值