添加pom文件 第二步、设置IDEA的自动编译: (1)File-Settings-Compiler勾选 Build Project automatically 快捷键 ctrl + shift + alt + /,选择Registry,勾上 Compiler autoMake allow when app running 相关文章: