Skip to content

Commit

Permalink
1.5.3: i18n access modifiers
Browse files Browse the repository at this point in the history
Adds a `publicVisibility` property to the i18n builder
  • Loading branch information
gdude2002 committed Oct 25, 2024
1 parent 0d8b605 commit 632e970
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 4 deletions.
7 changes: 7 additions & 0 deletions changes/1.5.3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Gradle Plugins 1.5.3

This version includes a small change for the KordEx plugin.

## KordEx Plugin

- The `i18n` builder now exposes a `publicVisibility` property. This defaults to `true`, but set it to `false` to produce generated objects using the `internal` visibility modifier.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ kotlin.incremental=true
org.gradle.jvmargs=-XX:MaxMetaspaceSize=1024m
org.gradle.parallel=true

projectVersion=1.5.2
projectVersion=1.5.3
2 changes: 1 addition & 1 deletion kordex/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ dependencies {
implementation("com.jcabi:jcabi-manifests:2.1.0")
implementation("com.squareup:kotlinpoet:1.18.1")
implementation("com.github.zafarkhaja:java-semver:0.10.2")
implementation("dev.kordex.i18n:i18n-generator:1.0.1")
implementation("dev.kordex.i18n:i18n-generator:1.0.3")
implementation("io.github.pdvrieze.xmlutil:core-jvm:0.86.3")
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json-jvm:1.6.3")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ object I18nHelper {
bundle = bundle.joinToString("."),
allProps = props,
className = extension.i18n.className.get(),
classPackage = extension.i18n.classPackage.get()
classPackage = extension.i18n.classPackage.get(),
publicVisibility = extension.i18n.publicVisibility.get()
)

translationsClass.writeTo(outputDirectory)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,6 @@ class KordExI18nSettings(props: PropertyFactory) {
val className: Property<String> = props.single("Translations")
val configureSourceSet: Property<Boolean> = props.boolean(true)
val outputDirectory: Property<File> = props.single()

val publicVisibility: Property<Boolean> = props.boolean(true)
}
1 change: 1 addition & 0 deletions testModule/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ kordEx {
i18n {
classPackage = "template.i18n"
translationBundle = "template.strings"
publicVisibility = false
}
}

Expand Down
2 changes: 1 addition & 1 deletion testModule/settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pluginManagement {
plugins {
val pluginVersion = "1.5.2"
val pluginVersion = "1.5.3"

kotlin("jvm") version "2.0.21"

Expand Down

0 comments on commit 632e970

Please sign in to comment.