Jacks0n23
12/13/2018, 9:15 AMmauin
12/13/2018, 9:16 AMmauin
12/13/2018, 9:18 AMJacks0n23
12/13/2018, 9:20 AMmauin
12/13/2018, 9:22 AMdebug = true
to the detekt { ... }
block and see if the gradle plugin prints some more hints?Jacks0n23
12/13/2018, 9:33 AMmauin
12/13/2018, 9:35 AM--plugins
argument in that?Jacks0n23
12/13/2018, 9:36 AMmauin
12/13/2018, 9:40 AMdetektPlugins
configuration.mauin
12/13/2018, 9:41 AMreports { detekt
. can you remove the detekt from that line?mauin
12/13/2018, 9:42 AMmauin
12/13/2018, 9:43 AMdependencies
block.Jacks0n23
12/13/2018, 9:45 AMreports { detekt
it's just misspell, nothing changedJacks0n23
12/13/2018, 9:47 AMapply plugin: 'io.gitlab.arturbosch.detekt'
apply from: rootProject.file('dependencies.gradle')
dependencies {
// detektPlugins compileDependencies.detektFormatting
// detekt "io.gitlab.arturbosch.detekt:detekt-cli:$detektVersion"
detektPlugins project(':mlca-rules')
}
nothing changed, same behaviourJacks0n23
12/13/2018, 9:49 AMmauin
12/13/2018, 9:52 AMJacks0n23
12/13/2018, 9:55 AMmauin
12/13/2018, 9:56 AM./gradlew :mlca-rules:build
before running ./gradlew detekt
?Jacks0n23
12/13/2018, 10:08 AMclass FindRetrofitAnnotatedMethods(config: Config = Config.empty) : Rule(config) {
override val issue: Issue = Issue("FindRetrofitAnnotatedMethods",
Severity.Maintainability,
"ProGuard obfuscation can cause (de)serialization issues if fields and classes are not in proguard-rules.pro.",
Debt.FIVE_MINS)
override fun visit(root: KtFile) {
report(CodeSmell(issue, Entity.from(root), "BOOOM"))
}
}
just to be sure that my rule work, but it didn'tJacks0n23
12/13/2018, 10:26 AMmauin
12/13/2018, 10:28 AMJacks0n23
12/13/2018, 10:35 AMpackage ru.tinkoff.mlca.internal
class InternalClass {}
and i get empty-blocks report
Ruleset: empty-blocks - 5min debt
EmptyClassBlock - [InternalClass] at /Users/a.guzenko/StudioProjects/mlca/data/src/main/java/ru/tinkoff/mlca/internal/InternalClass.kt:3:1
but not from my ruleset((mauin
12/13/2018, 10:38 AMJacks0n23
12/13/2018, 11:35 AMplugins = "mlca-rules.jar"
and when i run detekt it appears in arg
--plugins, mlca-rules.jar,
but… result the same: my rule is shown in Rulesets list but no report from custom rulesthuytrinh
12/14/2018, 3:11 PM