Skip to content

Commit

Permalink
Add internal project for test
Browse files Browse the repository at this point in the history
  • Loading branch information
Goooler committed Feb 8, 2024
1 parent 8096e27 commit 5460b5b
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 3 deletions.
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ spotless {
val r8: Configuration by configurations.creating

dependencies {
implementation(project(":internal"))
implementation("org.apache.poi:poi:5.2.5")
implementation("org.jdom:jdom2:2.0.6.1")

Expand Down
7 changes: 7 additions & 0 deletions internal/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
plugins {
kotlin("jvm")
}

java {
toolchain.languageVersion = JavaLanguageVersion.of(18)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package io.github.goooler.internal

import java.util.logging.LogManager
import java.util.logging.Logger

object InternalLogger {
private val logger: Logger = LogManager.getLogManager().getLogger("internal")

fun info(message: String) {
logger.info(message)
}
}
2 changes: 2 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,5 @@ dependencyResolutionManagement {
}

enableFeaturePreview("STABLE_CONFIGURATION_CACHE")

include(":internal")
5 changes: 2 additions & 3 deletions src/main/kotlin/io/github/goooler/exporter/Main.kt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package io.github.goooler.exporter

import org.apache.logging.log4j.LogManager
import org.apache.logging.log4j.Logger
import io.github.goooler.internal.InternalLogger

fun main(vararg args: String) {
val (command, inputPath, outputPath) = args
Expand All @@ -12,6 +11,6 @@ fun main(vararg args: String) {
}
}

val logger: Logger = LogManager.getLogger("Main")
val logger = InternalLogger

const val SUCCESS_OUTPUT = "Convert finished, output path:"

0 comments on commit 5460b5b

Please sign in to comment.