No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK

**

No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? idea maven 问题解决。

**

解决方法1:

在maven的setting.xml 文件 标签中加入指定JDK的版本,

     
      JDK-1.8       
             
        true       
        1.8       
             
             
        1.8       
        1.8       
        1.8       
             
    

解决方法2:

在项目的pom.xml 文件加入maven插件,中加入jdk路径


                  maven-compiler-plugin
                  3.1
                  
                        true
                        
                            C:\Program Files\Java\jdk1.8.0_181\bin\javac.exe(你的安装路径)
                        
                   
       

你可能感兴趣的:(java,maven,Oracle)