0
点赞
收藏
分享

微信扫一扫

maven项目模块中的main方法运行,提示java:程序不存在


报错描述

idea中 maven项目模块中的main方法运行,提示java:程序xxx不存在,xxx是存在dependency依赖模块中的。

工具

idea

解决

edit configurations

1.修改working directory 为当前模块module

before launch

1.移除build
2.增加run maven goal 修改working directory为当前模块module 填入compile命令
3.增加run maven goal 修改working directory为当前模块module 填入exec:java -Dexec.mainClass="com.xxxx.Main"
4.点击运行
5.完美解决问题

配置图

注意选择当前模块、当前模块、当前模块

maven项目模块中的main方法运行,提示java:程序不存在_maven

其他解决办法


举报

相关推荐

0 条评论