Intellij IDEA 使用Spring-boot-devTools无效解决办法

配置devtools

1.maven配置

在pom.xml文件中,增加如下插件依赖


 
        
            org.springframework.boot
            spring-boot-devtools
            true
        

在pom.xml文件中,增加如下插件


        
            
            
                org.springframework.boot
                spring-boot-maven-plugin
                
                    true
                
            
            
            
                maven-compiler-plugin
                
                    1.8
                    1.8
                
            
        
    

 

Eclipse

如果是eclipse开发,现在已经可以重启项目来使用了。但是idea的话,请看第二步的设置!

 

Intellij IDEA配置

1.设置中打开settings

Intellij IDEA 使用Spring-boot-devTools无效解决办法_第1张图片

2.按快捷键 Shift+Ctrl+Alt+/ ,选择 Registry

Intellij IDEA 使用Spring-boot-devTools无效解决办法_第2张图片

3.勾选compiler.automake.allow.when.app.running

Intellij IDEA 使用Spring-boot-devTools无效解决办法_第3张图片

你可能感兴趣的:(springboot,idea)