Skip to content

Commit

Permalink
fix: Back to jdk 17 + Fix some deprecated methods
Browse files Browse the repository at this point in the history
  • Loading branch information
EnzDev committed Dec 5, 2024
1 parent 0440b35 commit 57e3f60
Show file tree
Hide file tree
Showing 10 changed files with 37 additions and 34 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
java-version: 17

# Setup Gradle
- name: Setup Gradle
Expand Down Expand Up @@ -121,7 +121,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
java-version: 17

# Setup Gradle
- name: Setup Gradle
Expand Down Expand Up @@ -155,6 +155,7 @@ jobs:
checks: write
pull-requests: write
steps:

# Free GitHub Actions Environment Disk Space
- name: Maximize Build Space
uses: jlumbroso/free-disk-space@main
Expand All @@ -174,7 +175,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
java-version: 17

# Run Qodana inspections
- name: Qodana - Code Inspection
Expand All @@ -188,6 +189,7 @@ jobs:
needs: [ build ]
runs-on: ubuntu-latest
steps:

# Free GitHub Actions Environment Disk Space
- name: Maximize Build Space
uses: jlumbroso/free-disk-space@main
Expand All @@ -204,7 +206,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
java-version: 17

# Setup Gradle
- name: Setup Gradle
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
java-version: 17

# Setup Gradle
- name: Setup Gradle
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/run-ui-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
java-version: 17

# Setup Gradle
- name: Setup Gradle
Expand Down
9 changes: 6 additions & 3 deletions .run/Run IDE for UI Tests.run.xml → .run/Run IDE.run.xml
Original file line number Diff line number Diff line change
@@ -1,22 +1,25 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Run IDE for UI Tests" type="GradleRunConfiguration" factoryName="Gradle">
<configuration default="false" name="Run IDE" type="GradleRunConfiguration" factoryName="Gradle">
<log_file alias="idea.log" path="$PROJECT_DIR$/build/idea-sandbox/system/log/idea.log" />
<ExternalSystemSettings>
<option name="executionName" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="externalSystemIdString" value="GRADLE" />
<option name="scriptParameters" value="runIdeForUiTests" />
<option name="scriptParameters" value="" />
<option name="taskDescriptions">
<list />
</option>
<option name="taskNames">
<list />
<list>
<option value="runIde" />
</list>
</option>
<option name="vmOptions" />
</ExternalSystemSettings>
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
<DebugAllEnabled>false</DebugAllEnabled>
<RunAsTest>false</RunAsTest>
<method v="2" />
</configuration>
</component>
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,15 @@
</option>
<option name="taskNames">
<list>
<option value="runPluginVerifier" />
<option value="verifyPlugin" />
</list>
</option>
<option name="vmOptions" value="" />
</ExternalSystemSettings>
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
<DebugAllEnabled>false</DebugAllEnabled>
<method v="2">
<option name="Gradle.BeforeRunTask" enabled="true" tasks="clean" externalProjectPath="$PROJECT_DIR$" vmOptions="" scriptParameters="" />
</method>
<RunAsTest>false</RunAsTest>
<method v="2" />
</configuration>
</component>
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ dependencies {

// Set the JVM language level used to build the project.
kotlin {
jvmToolchain(21)
jvmToolchain(17)
}

// Configure IntelliJ Platform Gradle Plugin - read more: https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin-extension.html
Expand Down
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ pluginRepositoryUrl = https://plugins.jetbrains.com/plugin/17450-ngtranslate-too

# See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
# for insight into build numbers and IntelliJ Platform versions.
pluginSinceBuild = 242
pluginSinceBuild = 241
pluginUntilBuild = 243.*

# IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin-dependencies-extension.html#custom-target-platforms
Expand All @@ -22,11 +22,11 @@ platformPlugins =
platformBundledPlugins = JavaScript, AngularJS

# Gradle Releases -> https://github.com/gradle/gradle/releases
gradleVersion = 8.10.2
gradleVersion = 8.11.1

# Enable Gradle Configuration Cache -> https://docs.gradle.org/current/userguide/configuration_cache.html
org.gradle.configuration-cache = true
kotlin.stdlib.default.dependency = true
kotlin.stdlib.default.dependency = false

# Enable Gradle Build Cache -> https://docs.gradle.org/current/userguide/build_cache.html
org.gradle.caching = true
Expand Down
8 changes: 1 addition & 7 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,11 @@
[versions]
# libraries
annotations = "24.1.0"

# plugins
kotlin = "1.9.25"
changelog = "2.2.1"
intelliJPlatform = "2.1.0"
qodana = "2024.2.3"
qodana = "2024.2.6"
kover = "0.8.3"

[libraries]
annotations = { group = "org.jetbrains", name = "annotations", version.ref = "annotations" }

[plugins]
changelog = { id = "org.jetbrains.changelog", version.ref = "changelog" }
intelliJPlatform = { id = "org.jetbrains.intellij.platform", version.ref = "intelliJPlatform" }
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,23 +47,28 @@ class NgTranslateToolsetConfigurable(private val project: Project) : SearchableC
}

private fun createLangInput() = TextFieldWithBrowseButton().apply {

val descriptor = FileChooserDescriptor(true, false, false, false, false, false)
.withFileFilter(VirtualFile::isJsonFile)
.withTitle(NgTranslateToolsetBundle.message("configuration.modal.title.default_translation"))
.withDescription(NgTranslateToolsetBundle.message("configuration.modal.description.default_translation"))
addBrowseFolderListener(
NgTranslateToolsetBundle.message("configuration.modal.title.default_translation"),
NgTranslateToolsetBundle.message("configuration.modal.description.default_translation"),
descriptor.title,
descriptor.description,
project,
FileChooserDescriptor(true, false, false, false, false, false)
.withFileFilter { it.isJsonFile() }
descriptor
)
}

private fun createI18PathInput() = TextFieldWithBrowseButton().apply {
val descriptor = FileChooserDescriptor(false, true, false, false, false, false)
.withFileFilter(VirtualFile::isJsonFolder)
.withTitle(NgTranslateToolsetBundle.message("configuration.modal.title.translation_folder"))
.withDescription(NgTranslateToolsetBundle.message("configuration.modal.description.translation_folder"))
addBrowseFolderListener(
NgTranslateToolsetBundle.message("configuration.modal.title.translation_folder"),
NgTranslateToolsetBundle.message("configuration.modal.description.translation_folder"),
descriptor.title,
descriptor.description,
project,
FileChooserDescriptor(false, true, false, false, false, false)
.withFileFilter(VirtualFile::isJsonFolder)
descriptor
)
}

Expand Down

0 comments on commit 57e3f60

Please sign in to comment.