Skip to content

Commit

Permalink
upgrade to kotlin-logging 5 (#2157)
Browse files Browse the repository at this point in the history
Co-authored-by: paul-dingemans <paul-dingemans@users.noreply.github.com>
  • Loading branch information
oshai and paul-dingemans authored Jul 31, 2023
1 parent 760279e commit 06841b6
Show file tree
Hide file tree
Showing 39 changed files with 58 additions and 48 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,4 @@ val formattedCode =

## Logging

Ktlint uses the `io.github.microutils:kotlin-logging` which is a `slf4j` wrapper. As API consumer you can choose which logging framework you want to use and configure that framework to your exact needs. The [basic API Consumer](https://github.com/pinterest/ktlint/blob/master/ktlint-api-consumer/src/main/kotlin/com/example/ktlint/api/consumer/KtlintApiConsumer.kt) contains an example with `org.slf4j:slf4j-simple` as logging provider and a customized configuration which shows logging at `DEBUG` level for all classes except one specific class which only displays logging at `WARN` level.
Ktlint uses the `io.github.oshai:kotlin-logging` which is a `slf4j` wrapper. As API consumer you can choose which logging framework you want to use and configure that framework to your exact needs. The [basic API Consumer](https://github.com/pinterest/ktlint/blob/master/ktlint-api-consumer/src/main/kotlin/com/example/ktlint/api/consumer/KtlintApiConsumer.kt) contains an example with `org.slf4j:slf4j-simple` as logging provider and a customized configuration which shows logging at `DEBUG` level for all classes except one specific class which only displays logging at `WARN` level.
2 changes: 1 addition & 1 deletion documentation/snapshot/docs/api/custom-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,4 @@ val formattedCode =

## Logging

Ktlint uses the `io.github.microutils:kotlin-logging` which is a `slf4j` wrapper. As API consumer you can choose which logging framework you want to use and configure that framework to your exact needs. The [basic API Consumer](https://github.com/pinterest/ktlint/blob/master/ktlint-api-consumer/src/main/kotlin/com/example/ktlint/api/consumer/KtlintApiConsumer.kt) contains an example with `org.slf4j:slf4j-simple` as logging provider and a customized configuration which shows logging at `DEBUG` level for all classes except one specific class which only displays logging at `WARN` level.
Ktlint uses the `io.github.oshai:kotlin-logging` which is a `slf4j` wrapper. As API consumer you can choose which logging framework you want to use and configure that framework to your exact needs. The [basic API Consumer](https://github.com/pinterest/ktlint/blob/master/ktlint-api-consumer/src/main/kotlin/com/example/ktlint/api/consumer/KtlintApiConsumer.kt) contains an example with `org.slf4j:slf4j-simple` as logging provider and a customized configuration which shows logging at `DEBUG` level for all classes except one specific class which only displays logging at `WARN` level.
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ kotlin-plugin-dev = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", vers
dokka = "org.jetbrains.dokka:dokka-gradle-plugin:1.8.20"
ec4j = "org.ec4j.core:ec4j-core:0.3.0"
picocli = "info.picocli:picocli:4.7.4"
logging = "io.github.microutils:kotlin-logging-jvm:3.0.5"
logging = "io.github.oshai:kotlin-logging-jvm:5.0.1"
slf4j = "org.slf4j:slf4j-simple:2.0.7"
# TODO: update to 0.14.0 after upgrade to Kotlin Gradle Plugin 1.9
poko = "dev.drewhamilton.poko:poko-gradle-plugin:0.14.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import com.pinterest.ktlint.rule.engine.core.api.IndentConfig
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.INDENT_SIZE_PROPERTY
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.INDENT_STYLE_PROPERTY
import com.pinterest.ktlint.rule.engine.core.api.propertyTypes
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import java.io.File
import java.nio.file.Paths

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.pinterest.ktlint.api.consumer

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import java.nio.file.FileVisitResult
import java.nio.file.Files
import java.nio.file.Path
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import com.pinterest.ktlint.cli.reporter.core.api.KtlintCliError
import com.pinterest.ktlint.cli.reporter.core.api.KtlintCliError.Status.BASELINE_IGNORED
import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.core.api.RuleId
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.w3c.dom.Element
import org.xml.sax.SAXException
import java.io.IOException
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.pinterest.ktlint.cli.internal

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.jetbrains.kotlin.util.prefixIfNot
import java.io.File
import java.nio.file.FileSystem
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.api.EditorConfigOverride
import com.pinterest.ktlint.rule.engine.api.KtLintRuleEngine
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.CODE_STYLE_PROPERTY
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import picocli.CommandLine
import java.nio.file.Paths

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.pinterest.ktlint.cli.internal

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import java.io.File
import java.io.IOException
import java.math.BigInteger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ import com.pinterest.ktlint.rule.engine.core.api.editorconfig.RuleExecution
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.createRuleExecutionEditorConfigProperty
import com.pinterest.ktlint.rule.engine.core.api.propertyTypes
import com.pinterest.ktlint.ruleset.standard.rules.FILENAME_RULE_ID
import mu.KLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.DelegatingKLogger
import io.github.oshai.kotlinlogging.KLogger
import io.github.oshai.kotlinlogging.KotlinLogging
import org.jetbrains.kotlin.utils.addToStdlib.applyIf
import picocli.CommandLine
import picocli.CommandLine.Command
Expand Down Expand Up @@ -377,12 +378,19 @@ internal class KtlintCommandLine {
logger =
KotlinLogging
.logger {}
.setDefaultLoggerModifier { logger ->
(logger.underlyingLogger as Logger).level = minLogLevel
}
.setDefaultLoggerModifier { logger -> logger.level = minLogLevel }
.initKtLintKLogger()
}

private var KLogger.level: Level?
get() = underlyingLogger()?.level
set(value) { underlyingLogger()?.level = value }

private fun KLogger.underlyingLogger(): Logger? =
@Suppress("UNCHECKED_CAST")
(this as? DelegatingKLogger<Logger>)
?.underlyingLogger

private fun assertStdinAndPatternsFromStdinOptionsMutuallyExclusive() {
if (stdin && stdinDelimiter != null) {
throw ParameterException(
Expand Down Expand Up @@ -595,7 +603,7 @@ internal class KtlintCommandLine {
status = KOTLIN_PARSE_EXCEPTION,
)
is KtLintRuleException -> {
logger.debug("Internal Error (${e.ruleId}) in ${code.fileNameOrStdin()} at position '${e.line}:${e.col}", e)
logger.debug(e) { "Internal Error (${e.ruleId}) in ${code.fileNameOrStdin()} at position '${e.line}:${e.col}" }
KtlintCliError(
line = e.line,
col = e.col,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package com.pinterest.ktlint.cli.internal
import com.pinterest.ktlint.cli.internal.CustomJarProviderCheck.ERROR_WHEN_DEPRECATED_PROVIDER_IS_FOUND
import com.pinterest.ktlint.cli.internal.CustomJarProviderCheck.ERROR_WHEN_REQUIRED_PROVIDER_IS_MISSING
import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import java.net.URL
import java.net.URLClassLoader
import java.util.ServiceConfigurationError
Expand Down Expand Up @@ -42,7 +42,7 @@ internal fun <T> Class<T>.loadFromJarFiles(
.filterNot { providerIdsFromKtlintJars.contains(providerId(it)) }
if (providers.isEmpty()) {
if (customJarProviderCheck == ERROR_WHEN_REQUIRED_PROVIDER_IS_MISSING) {
if (LOGGER.isDebugEnabled) {
if (LOGGER.isDebugEnabled()) {
LOGGER.error {
"""
JAR file '${url.path}' is missing a class implementing interface '$canonicalName'
Expand Down Expand Up @@ -70,7 +70,7 @@ internal fun <T> Class<T>.loadFromJarFiles(
providers
.mapNotNull {
if (customJarProviderCheck == ERROR_WHEN_DEPRECATED_PROVIDER_IS_FOUND) {
if (LOGGER.isDebugEnabled) {
if (LOGGER.isDebugEnabled()) {
LOGGER.error {
"""
JAR file '${url.path}' contains a class implementing an unsupported interface '$canonicalName'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import com.pinterest.ktlint.cli.reporter.core.api.KtlintCliError
import com.pinterest.ktlint.cli.reporter.core.api.ReporterProviderV2
import com.pinterest.ktlint.cli.reporter.core.api.ReporterV2
import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import java.io.File
import java.io.IOException
import java.io.PrintStream
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package com.pinterest.ktlint.cli

import com.pinterest.ktlint.cli.environment.OsEnvironment
import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.assertj.core.api.AbstractAssert
import org.assertj.core.api.AbstractBooleanAssert
import org.assertj.core.api.AbstractIntegerAssert
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package com.pinterest.ktlint.cli.internal

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.test.KtlintTestFileSystem
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.assertj.core.api.Assertions.assertThat
import org.junit.jupiter.api.AfterEach
import org.junit.jupiter.api.BeforeEach
Expand Down
4 changes: 2 additions & 2 deletions ktlint-logger/api/ktlint-logger.api
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
public final class com/pinterest/ktlint/logger/api/KtLintKLoggerInitializerKt {
public static final fun initKtLintKLogger (Lmu/KLogger;)Lmu/KLogger;
public static final fun setDefaultLoggerModifier (Lmu/KLogger;Lkotlin/jvm/functions/Function1;)Lmu/KLogger;
public static final fun initKtLintKLogger (Lio/github/oshai/kotlinlogging/KLogger;)Lio/github/oshai/kotlinlogging/KLogger;
public static final fun setDefaultLoggerModifier (Lio/github/oshai/kotlinlogging/KLogger;Lkotlin/jvm/functions/Function1;)Lio/github/oshai/kotlinlogging/KLogger;
}

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.pinterest.ktlint.logger.api

import mu.KLogger
import io.github.oshai.kotlinlogging.KLogger

/**
* Default modifier for the KLogger. It can be set only once via [setDefaultLoggerModifier] but it should be set before the first invocation
Expand Down
1 change: 1 addition & 0 deletions ktlint-rule-engine-core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ dependencies {

testImplementation(projects.ktlintTest)
testImplementation(projects.ktlintRuleEngine)
testRuntimeOnly(libs.slf4j)
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package com.pinterest.ktlint.rule.engine.core.api.editorconfig
import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.core.api.Rule
import dev.drewhamilton.poko.Poko
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.model.Property
import org.ec4j.core.model.PropertyType
import org.ec4j.core.model.PropertyType.PropertyValue
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.pinterest.ktlint.rule.engine.core.api.editorconfig

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.model.PropertyType

private const val MAX_LINE_LENGTH_PROPERTY_ANDROID_STUDIO_CODE_STYLE = 100 // https://developer.android.com/kotlin/style-guide#line_wrapping
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import com.pinterest.ktlint.rule.engine.internal.RuleExecutionContext
import com.pinterest.ktlint.rule.engine.internal.RuleExecutionContext.Companion.createRuleExecutionContext
import com.pinterest.ktlint.rule.engine.internal.ThreadSafeEditorConfigCache.Companion.THREAD_SAFE_EDITOR_CONFIG_CACHE
import com.pinterest.ktlint.rule.engine.internal.VisitorProvider
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.Resource
import org.ec4j.core.model.PropertyType.EndOfLineValue.crlf
import org.ec4j.core.model.PropertyType.EndOfLineValue.lf
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.api.EditorConfigDefaults
import com.pinterest.ktlint.rule.engine.api.EditorConfigDefaults.Companion.EMPTY_EDITOR_CONFIG_DEFAULTS
import com.pinterest.ktlint.rule.engine.internal.ThreadSafeEditorConfigCache.Companion.THREAD_SAFE_EDITOR_CONFIG_CACHE
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.Resource
import java.nio.charset.StandardCharsets
import java.nio.file.Path
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.pinterest.ktlint.rule.engine.internal

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.Resource
import org.ec4j.core.ResourcePropertiesService
import org.jetbrains.kotlin.konan.file.File
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import com.pinterest.ktlint.rule.engine.internal.FormatterTags.Companion.FORMATT
import com.pinterest.ktlint.rule.engine.internal.FormatterTags.Companion.FORMATTER_TAG_OFF_ENABLED_PROPERTY
import com.pinterest.ktlint.rule.engine.internal.FormatterTags.Companion.FORMATTER_TAG_ON_ENABLED_PROPERTY
import com.pinterest.ktlint.rule.engine.internal.ThreadSafeEditorConfigCache.Companion.THREAD_SAFE_EDITOR_CONFIG_CACHE
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.EditorConfigLoader
import org.ec4j.core.PropertyTypeRegistry
import org.ec4j.core.Resource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package com.pinterest.ktlint.rule.engine.internal

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.api.KtLintRuleEngine
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.jetbrains.kotlin.cli.common.CLIConfigurationKeys
import org.jetbrains.kotlin.cli.common.messages.MessageCollector
import org.jetbrains.kotlin.cli.jvm.compiler.EnvironmentConfigFiles
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import com.pinterest.ktlint.rule.engine.internal.rulefilter.InternalRuleProvider
import com.pinterest.ktlint.rule.engine.internal.rulefilter.RuleExecutionRuleFilter
import com.pinterest.ktlint.rule.engine.internal.rulefilter.RunAfterRuleFilter
import com.pinterest.ktlint.rule.engine.internal.rulefilter.applyRuleFilters
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.jetbrains.kotlin.com.intellij.lang.ASTNode
import org.jetbrains.kotlin.com.intellij.lang.FileASTNode
import org.jetbrains.kotlin.com.intellij.psi.PsiElement
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import com.pinterest.ktlint.rule.engine.core.api.RuleId
import com.pinterest.ktlint.rule.engine.core.api.RuleProvider
import com.pinterest.ktlint.rule.engine.core.api.RuleSetId
import com.pinterest.ktlint.rule.engine.internal.rules.KTLINT_SUPPRESSION_RULE_ID
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging

private val LOGGER = KotlinLogging.logger {}.initKtLintKLogger()

Expand All @@ -25,7 +25,7 @@ internal class RuleProviderSorter {
ruleProviders
.sort()
.also { sortedRuleProviders ->
if (LOGGER.isDebugEnabled) {
if (LOGGER.isDebugEnabled()) {
logSortedRuleProviders(sortedRuleProviders)
}
}
Expand All @@ -39,7 +39,7 @@ internal class RuleProviderSorter {
sortedRuleProviders
.joinToString(prefix = "Rules will be executed in order below:") {
"\n - ${it.ruleId.value}"
}.also { LOGGER.debug(it) }
}.also { LOGGER.debug { it } }
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.pinterest.ktlint.rule.engine.internal

import com.pinterest.ktlint.logger.api.initKtLintKLogger
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.Cache
import org.ec4j.core.EditorConfigLoader
import org.ec4j.core.Resource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.core.api.Rule
import com.pinterest.ktlint.rule.engine.core.api.RuleProvider
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.EditorConfig
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging

private val LOGGER = KotlinLogging.logger {}.initKtLintKLogger()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import com.pinterest.ktlint.logger.api.initKtLintKLogger
import com.pinterest.ktlint.rule.engine.api.KtLintRuleEngine
import com.pinterest.ktlint.rule.engine.core.api.RuleProvider
import com.pinterest.ktlint.rule.engine.internal.rules.KtlintSuppressionRule
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging

private val LOGGER = KotlinLogging.logger {}.initKtLintKLogger()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import com.pinterest.ktlint.rule.engine.core.api.editorconfig.RuleExecution
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.ktLintRuleExecutionPropertyName
import com.pinterest.ktlint.rule.engine.core.api.editorconfig.ktLintRuleSetExecutionPropertyName
import com.pinterest.ktlint.rule.engine.internal.rules.KTLINT_SUPPRESSION_RULE_ID
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging

private val LOGGER = KotlinLogging.logger {}.initKtLintKLogger()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import com.pinterest.ktlint.rule.engine.internal.rulefilter.RunAfterRuleFilter.R
import com.pinterest.ktlint.rule.engine.internal.rulefilter.RunAfterRuleFilter.RunAfterRuleOrderModifier.BLOCK_UNTIL_RUN_AFTER_RULE_IS_LOADED
import com.pinterest.ktlint.rule.engine.internal.rulefilter.RunAfterRuleFilter.RunAfterRuleOrderModifier.IGNORE
import com.pinterest.ktlint.rule.engine.internal.rulefilter.RunAfterRuleFilter.RunAfterRuleOrderModifier.REQUIRED_RUN_AFTER_RULE_NOT_LOADED
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging

private val LOGGER = KotlinLogging.logger {}.initKtLintKLogger()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import com.pinterest.ktlint.ruleset.standard.rules.ImportOrderingRule.Companion.
import com.pinterest.ktlint.ruleset.standard.rules.internal.importordering.ImportSorter
import com.pinterest.ktlint.ruleset.standard.rules.internal.importordering.PatternEntry
import com.pinterest.ktlint.ruleset.standard.rules.internal.importordering.parseImportsLayout
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.ec4j.core.model.PropertyType
import org.jetbrains.kotlin.com.intellij.lang.ASTNode
import org.jetbrains.kotlin.com.intellij.psi.PsiWhiteSpace
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ import com.pinterest.ktlint.rule.engine.core.api.prevCodeSibling
import com.pinterest.ktlint.rule.engine.core.api.prevLeaf
import com.pinterest.ktlint.rule.engine.core.api.prevSibling
import com.pinterest.ktlint.ruleset.standard.StandardRule
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.jetbrains.kotlin.com.intellij.lang.ASTNode
import org.jetbrains.kotlin.com.intellij.psi.PsiComment
import org.jetbrains.kotlin.com.intellij.psi.impl.source.tree.LeafPsiElement
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import com.pinterest.ktlint.rule.engine.core.api.prevLeaf
import com.pinterest.ktlint.rule.engine.core.api.upsertWhitespaceAfterMe
import com.pinterest.ktlint.rule.engine.core.api.upsertWhitespaceBeforeMe
import com.pinterest.ktlint.ruleset.standard.StandardRule
import mu.KotlinLogging
import io.github.oshai.kotlinlogging.KotlinLogging
import org.jetbrains.kotlin.com.intellij.lang.ASTNode

private val LOGGER = KotlinLogging.logger {}.initKtLintKLogger()
Expand Down
Loading

0 comments on commit 06841b6

Please sign in to comment.