小编Ish*_*ood的帖子

IntelliJ是在.gitignore文件中提到的项目窗口中隐藏文件夹,如何在项目窗口中显示该文件夹?

IntelliJ项目窗口和.gitignore文件快照

  • 忽略构建文件夹不会在项目窗口中显示它.
  • 在.gitignore中评论.gradle确实在项目窗口中显示它.

我想在项目窗口中显示.gradle和build文件夹,但我也想将它们包含在.gitignore文件中.

intellij-idea

9
推荐指数
1
解决办法
4099
查看次数

无法在调试模式下启动 SpringBoot 应用程序,关闭 org.springframework.context.annotation.AnnotationConfigApplicationContext

我的应用程序是一个 Web 应用程序,当使用“mvn spring-boot:run”运行时,我能够成功命中端点。唯一的问题是在 intellij 中以调试模式运行时应用程序关闭并且无法调试我的应用程序。

pom.xml:

<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>1.5.2.RELEASE</version>
    <relativePath/> <!-- lookup parent body repository -->
</parent>
<dependencies>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-activemq</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-web</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-tomcat</artifactId>
        <!--<scope>provided</scope>-->
    </dependency>

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>

</dependencies>
Run Code Online (Sandbox Code Playgroud)

输出:

=========================
AUTO-CONFIGURATION REPORT
=========================

Positive matches:
-----------------
  .....

Negative matches:
-----------------
   ActiveMQAutoConfiguration:
      Did not match:
         - @ConditionalOnMissingBean (types: javax.jms.ConnectionFactory; SearchStrategy: all) found bean 'getConnectionFactory' (OnBeanCondition)
      Matched:
         - @ConditionalOnClass found required classes 'javax.jms.ConnectionFactory', 'org.apache.activemq.ActiveMQConnectionFactory'; @ConditionalOnMissingClass did not find unwanted class (OnClassCondition) …
Run Code Online (Sandbox Code Playgroud)

spring intellij-idea spring-boot

7
推荐指数
2
解决办法
2万
查看次数

如何在Spring Data jpa @Query中引用用外部文件编写的长查询

  • 我想在外部文件中写入查询(属性或Yaml)以加载数据库。--
  • 这是长查询,放在XXXRepository类中的@Query(“ long query”)中时看起来不太好看。
  • 有没有办法将此查询写入外部文件(属性,yaml,xml或json),然后在spring数据jpa中的@Query()中调用该文件?

spring-data spring-data-jpa spring-boot

6
推荐指数
1
解决办法
2652
查看次数

如何在 IntelliJ http 文件中单击运行多个 http 请求,而不是单独运行它们

我在 http 文件中有 10 个 http 请求,希望通过单击来运行它们,而不是单击每个请求并查看输出。后续请求使用先前请求的输出,因此我想以自动方式连续运行它们。

intellij-idea

5
推荐指数
1
解决办法
7543
查看次数