Skip to content
This repository has been archived by the owner on Jan 6, 2024. It is now read-only.

how to use Ktlint with detekt #78

Closed
afaucogney opened this issue Oct 1, 2018 · 4 comments
Closed

how to use Ktlint with detekt #78

afaucogney opened this issue Oct 1, 2018 · 4 comments

Comments

@afaucogney
Copy link

Hi,

When using detekt in the IDE, you can easily integrate Ktlint by adding detekt dependency. How may we do that in the case of sonar-plugin ?

dependencies {
    detekt "io.gitlab.arturbosch.detekt:detekt-formatting:[version]"
}
@arturbosch
Copy link
Member

It is not possible for now sorry. There is #1 which should tackle this.

@romtsn
Copy link

romtsn commented Jul 1, 2019

@arturbosch So, just to clarify this one is not the current repository right? I'd be in for contributing ktlint rules into SonarLint to be able to have in IDE via plugin, but currently have no context on that 🙈 I thought SonarLint Kotlin uses your repository, but looked up for the same rules in detekt and didn't find them.

@arturbosch
Copy link
Member

Hey @rom4ek, nope the official sonar-kotlin plugin is not our plugin. But their plugin allows to import detekt's report files to have both rule results inside the sonarqube.
I haven't used SonarLint so I don't know if they use the same plugins or not :/

@arturbosch
Copy link
Member

I've just pushed a commit which integrates KtLint rules over detekt to sonar-kotlin -> 63643bc

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants