JetBrains is developing a code-quality inspection tool called Qodana. It brings the intelligent code checking that JetBrains IDE has into the project CI/CD pipeline. It identifies errors, security holes, duplicates and defects in code and suggests fixes. It makes it easy for developers to improve the structure of their code to make it conform to numerous guidelines and standards, addressing potential performance problems.

Qodana

Qodana consists of two main parts: a sophisticated, GUI-free IntelliJ IDEA engine designed specifically for use in CI pipelines as a typical “pipelining” tool; Another Web-based interactive reporting UI.

Qodana is currently in early development, but an early preview is available. Ultimately, Qodana will offer a variety of service forms:

  • Docker image for any CI tool
  • GitHub Actions
  • Standalone Qodana App
  • TeamCity plugin
  • The cloud service

The roadmap

Qodana currently only supports PHP, Java, and Kotlin, and will eventually support languages and technologies from the JetBrains IDE family. And there are more new features in development, such as version/branch comparison, advanced code quality objective management, profile change detection, code duplication analysis across projects, third-party license monitoring, and security detection including stain analysis.

Qodana trial

First, pull the image from Docker Hub (latest version) :

docker pull jetbrains/qodana
Copy the code

Run a temporary Docker container to analyze the native code:

docker run --rm -it -v <source-directory>/:/data/project/ -p 8080:8080 jetbrains/qodana --show-report
Copy the code

Here source-directory should point to the root directory of your project.

For example, scan the local C :\Users\felord\IdeaProjects\payment-spring-boot:

docker run --rm -it -v c:\Users\felord\IdeaProjects\payment-spring-boot:/data/project/ -p 8080:8080 jetbrains/qodana --show-report
Copy the code

After the scan is complete, an inspection report will be generated. You can view the report in your browser by opening http://localhost:8080.

Like JetBrains’ IDE, it’s very simple to use, so you can check it out if you’re interested. At present, the project has provided a user guide on GitHub, for those who are good at English, you can go to research. I am: code farmer xiao Pangge, follow me for the latest programming news.

Follow our public id: Felordcn for more information

Personal blog: https://felord.cn