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

Adding more documentation #916

Merged
merged 4 commits into from
Jun 10, 2021
Merged
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
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,19 @@ class SomeClass {
}
}
```

## Suppress groups of inspections
It is easy to suppress even groups of inspections in diKTat.

These groups are linked to chapters of [Codestyle](info/guide/diktat-coding-convention.md).

To disable chapters, you will need to add the following configuration to common configuration (`- name: DIKTAT_COMMON`):
```yaml
disabledChapters: "1, 2, 3"
```

Mapping of inspections to chapters can be found in [Groups of Inspections](info/rules-mapping.md) .

## How to contribute?

Main components are:
Expand Down
3 changes: 3 additions & 0 deletions diktat-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
# put your package name here - it will be autofixed and checked
domainName: org.cqfn.diktat
# testDirs: test
# can also use chapter names here (not only numbers)
# expected values: disabledChapters: "Naming, Comments, General, Variables, Functions, Classes"
# or: "1, 2, 3, 4, 5, 6"
disabledChapters: ""
testDirs: test
kotlinVersion: 1.5
Expand Down
9 changes: 8 additions & 1 deletion diktat-gradle-plugin/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,11 @@ To avoid versions duplication, diktat and ktlint versions are passed to gradle v
These versions are then written in a file and then included in the plugin jar to determine dependencies for JavaExec.

Gradle plugin marker pom, which is normally produced by `java-gradle-plugin` plugin during gradle build,
is added manually as a maven module.
is added manually as a maven module.

Please be advised that to run functional tests of Gradle plugin you will need to have Java 11 or **older**.
This does not affect the plugin itself and only affect functional tests :
```
Starting Build
java.lang.NoClassDefFoundError: Could not initialize class org.codehaus.groovy.vmplugin.v7.Java7
```
2 changes: 2 additions & 0 deletions diktat-rules/src/main/resources/diktat-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
# put your package name here - it will be autofixed and checked
domainName: your.name.here
testDirs: test
# expected values: disabledChapters: "Naming, Comments, General, Variables, Functions, Classes"
# or: "1, 2, 3, 4, 5, 6"
disabledChapters: ""
kotlinVersion: 1.5
srcDirectories: "main"
Expand Down