Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configure Qodana #458

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,9 @@ jobs:
name: pluginVerifier-result
path: ${{ github.workspace }}/build/reports/pluginVerifier

# TODO: Enable Qodana
# # Run Qodana inspections
# - name: Qodana - Code Inspection
# uses: JetBrains/[email protected]
# Run Qodana inspections
- name: Qodana - Code Inspection
uses: JetBrains/[email protected]

# Prepare plugin archive content for creating artifact
- name: Prepare Plugin Artifact
Expand Down
17 changes: 17 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
plugins {
id "org.jetbrains.intellij" version "1.7.0"
id "org.jetbrains.changelog" version "1.3.1"
id "org.jetbrains.qodana" version "0.1.13"
}

String properties(String key) {
Expand Down Expand Up @@ -177,3 +178,19 @@ test {
changelog {
version = properties('pluginVersion')
}

Boolean getEnvBool(String key, Boolean defaultValue) {
String v = System.getenv(key)
if (v == null) {
return defaultValue
} else {
return v.toBoolean()
}
}

qodana {
cachePath = "$projectDir/.qodana"
reportPath = "$projectDir/build/reports/inspections"
saveReport = true
showReport = getEnvBool('QODANA_SHOW_REPORT', false)
}
6 changes: 6 additions & 0 deletions qodana.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Qodana configuration:
# https://www.jetbrains.com/help/qodana/qodana-yaml.html

version: 1.0
profile:
name: qodana.recommended