启动springboot报错:程序包org.springframework.boot不存在

前言

编译工程,提示「程序包org.springframework.boot不存在」、但是maven本地仓库是有springboot包的,所以怀疑是maven没问题,但是idea编译有问题

启动springboot报错:程序包org.springframework.boot不存在_第1张图片

解决方法

在IDEA需要在Setting里将 Delegate IDE build/run actions to Maven勾选上如下图:

启动springboot报错:程序包org.springframework.boot不存在_第2张图片

spring-boot工程建议开启这个,减少未知编译问题,这个选项是委托给maven插件,有些插件是可以直接打包整个工程到jar

你可能感兴趣的:(spring,boot,java,intellij-idea)