From 7190afcaba1fd2a02047c7f57200d9c4603c23b4 Mon Sep 17 00:00:00 2001 From: 0verEngineer Date: Mon, 18 Mar 2024 16:43:52 +0100 Subject: [PATCH 1/6] Compability with 2024.1 --- CHANGELOG.md | 4 ++++ gradle.properties | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f0e28e..dabc8d3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ ## [Unreleased] +## [0.5.2] +### Added +- Compability with 2024.1 + ## [0.5.1] ### Fixed - SettingsBundle missing default (Settings not working with non english os language) diff --git a/gradle.properties b/gradle.properties index f940f93..a69b43f 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,11 +2,11 @@ pluginGroup = org.OverEngineer pluginName = InlineProblems pluginRepositoryUrl = https://github.com/OverEngineer/InlineProblems # SemVer format -> https://semver.org -pluginVersion = 0.5.1 +pluginVersion = 0.5.2 # Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html pluginSinceBuild = 212.5 -pluginUntilBuild = 233.* +pluginUntilBuild = 243.* # IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html#configuration-intellij-extension platformType = IC From 81e1693bca527c3f30871a216c27609450e6f4a3 Mon Sep 17 00:00:00 2001 From: 0verEngineer Date: Mon, 18 Mar 2024 22:06:11 +0100 Subject: [PATCH 2/6] Try to fix ci build --- build.gradle.kts | 4 ++-- gradle.properties | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index ac7fe5e..a3a6053 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -58,8 +58,8 @@ tasks { // Set the JVM compatibility versions withType { - sourceCompatibility = "11" - targetCompatibility = "11" + sourceCompatibility = "17" + targetCompatibility = "17" } patchPluginXml { diff --git a/gradle.properties b/gradle.properties index a69b43f..3e4cded 100644 --- a/gradle.properties +++ b/gradle.properties @@ -5,12 +5,12 @@ pluginRepositoryUrl = https://github.com/OverEngineer/InlineProblems pluginVersion = 0.5.2 # Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html -pluginSinceBuild = 212.5 +pluginSinceBuild = 223.3 pluginUntilBuild = 243.* # IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html#configuration-intellij-extension platformType = IC -platformVersion = 2021.2.4 +platformVersion = 2022.3.3 # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 From d7768cd664cd833a67afa44c3c1be63683ad401f Mon Sep 17 00:00:00 2001 From: 0verEngineer Date: Mon, 18 Mar 2024 22:14:37 +0100 Subject: [PATCH 3/6] Update ci to java 17 as well --- .github/workflows/beta-release.yml | 2 +- .github/workflows/build.yml | 4 ++-- .github/workflows/release.yml | 4 ++-- .github/workflows/run-ui-tests.yml | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/beta-release.yml b/.github/workflows/beta-release.yml index a0e8cd4..ab1de92 100644 --- a/.github/workflows/beta-release.yml +++ b/.github/workflows/beta-release.yml @@ -36,7 +36,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: zulu - java-version: 11 + java-version: 17 # Publish the plugin to the Marketplace, this should automatically use the 'beta' channel because we changed the # version in gradle.properties to version-beta diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 41895cc..0134cb7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -48,12 +48,12 @@ jobs: - name: Gradle Wrapper Validation uses: gradle/wrapper-validation-action@v1.0.6 - # Setup Java 11 environment for the next steps + # Setup Java 17 environment for the next steps - name: Setup Java uses: actions/setup-java@v3 with: distribution: zulu - java-version: 11 + java-version: 17 # Set environment variables - name: Export Properties diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c39feeb..3f4ebe7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -24,12 +24,12 @@ jobs: with: ref: ${{ github.event.release.tag_name }} - # Setup Java 11 environment for the next steps + # Setup Java 17 environment for the next steps - name: Setup Java uses: actions/setup-java@v3 with: distribution: zulu - java-version: 11 + java-version: 17 # Publish the plugin to the Marketplace - name: Publish Plugin diff --git a/.github/workflows/run-ui-tests.yml b/.github/workflows/run-ui-tests.yml index 363d9e8..957eab8 100644 --- a/.github/workflows/run-ui-tests.yml +++ b/.github/workflows/run-ui-tests.yml @@ -35,12 +35,12 @@ jobs: - name: Fetch Sources uses: actions/checkout@v3 - # Setup Java 11 environment for the next steps + # Setup Java 17 environment for the next steps - name: Setup Java uses: actions/setup-java@v3 with: distribution: zulu - java-version: 11 + java-version: 17 # Run IDEA prepared for UI testing - name: Run IDE From 585bd956922536e486885343b4be52931d27fe8f Mon Sep 17 00:00:00 2001 From: 0verEngineer Date: Mon, 18 Mar 2024 22:14:37 +0100 Subject: [PATCH 4/6] Revert "Update ci to java 17 as well" This reverts commit d7768cd664cd833a67afa44c3c1be63683ad401f. --- .github/workflows/beta-release.yml | 2 +- .github/workflows/build.yml | 4 ++-- .github/workflows/release.yml | 4 ++-- .github/workflows/run-ui-tests.yml | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/beta-release.yml b/.github/workflows/beta-release.yml index ab1de92..a0e8cd4 100644 --- a/.github/workflows/beta-release.yml +++ b/.github/workflows/beta-release.yml @@ -36,7 +36,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: zulu - java-version: 17 + java-version: 11 # Publish the plugin to the Marketplace, this should automatically use the 'beta' channel because we changed the # version in gradle.properties to version-beta diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0134cb7..41895cc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -48,12 +48,12 @@ jobs: - name: Gradle Wrapper Validation uses: gradle/wrapper-validation-action@v1.0.6 - # Setup Java 17 environment for the next steps + # Setup Java 11 environment for the next steps - name: Setup Java uses: actions/setup-java@v3 with: distribution: zulu - java-version: 17 + java-version: 11 # Set environment variables - name: Export Properties diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3f4ebe7..c39feeb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -24,12 +24,12 @@ jobs: with: ref: ${{ github.event.release.tag_name }} - # Setup Java 17 environment for the next steps + # Setup Java 11 environment for the next steps - name: Setup Java uses: actions/setup-java@v3 with: distribution: zulu - java-version: 17 + java-version: 11 # Publish the plugin to the Marketplace - name: Publish Plugin diff --git a/.github/workflows/run-ui-tests.yml b/.github/workflows/run-ui-tests.yml index 957eab8..363d9e8 100644 --- a/.github/workflows/run-ui-tests.yml +++ b/.github/workflows/run-ui-tests.yml @@ -35,12 +35,12 @@ jobs: - name: Fetch Sources uses: actions/checkout@v3 - # Setup Java 17 environment for the next steps + # Setup Java 11 environment for the next steps - name: Setup Java uses: actions/setup-java@v3 with: distribution: zulu - java-version: 17 + java-version: 11 # Run IDEA prepared for UI testing - name: Run IDE From 93abc7e05b7c38e2484498fe3c7f69dbd8d9f61e Mon Sep 17 00:00:00 2001 From: 0verEngineer Date: Mon, 18 Mar 2024 22:06:11 +0100 Subject: [PATCH 5/6] Revert "Try to fix ci build" This reverts commit 81e1693bca527c3f30871a216c27609450e6f4a3. --- build.gradle.kts | 4 ++-- gradle.properties | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index a3a6053..ac7fe5e 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -58,8 +58,8 @@ tasks { // Set the JVM compatibility versions withType { - sourceCompatibility = "17" - targetCompatibility = "17" + sourceCompatibility = "11" + targetCompatibility = "11" } patchPluginXml { diff --git a/gradle.properties b/gradle.properties index 3e4cded..a69b43f 100644 --- a/gradle.properties +++ b/gradle.properties @@ -5,12 +5,12 @@ pluginRepositoryUrl = https://github.com/OverEngineer/InlineProblems pluginVersion = 0.5.2 # Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html -pluginSinceBuild = 223.3 +pluginSinceBuild = 212.5 pluginUntilBuild = 243.* # IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html#configuration-intellij-extension platformType = IC -platformVersion = 2022.3.3 +platformVersion = 2021.2.4 # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 From bffb3bf5f1b9c0c7dfc38c667e955e973b6ee064 Mon Sep 17 00:00:00 2001 From: 0verEngineer Date: Thu, 21 Mar 2024 20:31:56 +0100 Subject: [PATCH 6/6] Update the ci workflow to match the plugin template --- .github/workflows/build.yml | 149 ++++++++++++++++++++++++++---------- 1 file changed, 110 insertions(+), 39 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 41895cc..6b85c2c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,6 +31,7 @@ jobs: outputs: version: ${{ steps.properties.outputs.version }} changelog: ${{ steps.properties.outputs.changelog }} + pluginVerifierHomeDir: ${{ steps.properties.outputs.pluginVerifierHomeDir }} steps: # Free GitHub Actions Environment Disk Space @@ -42,19 +43,25 @@ jobs: # Check out current repository - name: Fetch Sources - uses: actions/checkout@v3 + uses: actions/checkout@v4 # Validate wrapper - name: Gradle Wrapper Validation - uses: gradle/wrapper-validation-action@v1.0.6 + uses: gradle/wrapper-validation-action@v2 # Setup Java 11 environment for the next steps - name: Setup Java - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: zulu java-version: 11 + # Setup Gradle + - name: Setup Gradle + uses: gradle/actions/setup-gradle@v3 + with: + gradle-home-cache-cleanup: true + # Set environment variables - name: Export Properties id: properties @@ -74,36 +81,9 @@ jobs: echo "EOF" >> $GITHUB_OUTPUT ./gradlew listProductsReleases # prepare list of IDEs for Plugin Verifier - # Run tests - - name: Run Tests - run: ./gradlew check - - # Collect Tests Result of failed tests - - name: Collect Tests Result - if: ${{ failure() }} - uses: actions/upload-artifact@v3 - with: - name: tests-result - path: ${{ github.workspace }}/build/reports/tests - - # Cache Plugin Verifier IDEs - - name: Setup Plugin Verifier IDEs Cache - uses: actions/cache@v3 - with: - path: ${{ steps.properties.outputs.pluginVerifierHomeDir }}/ides - key: plugin-verifier-${{ hashFiles('build/listProductsReleases.txt') }} - - # Run Verify Plugin task and IntelliJ Plugin Verifier tool - - name: Run Plugin Verification tasks - run: ./gradlew runPluginVerifier -Dplugin.verifier.home.dir=${{ steps.properties.outputs.pluginVerifierHomeDir }} - - # Collect Plugin Verifier Result - - name: Collect Plugin Verifier Result - if: ${{ always() }} - uses: actions/upload-artifact@v3 - with: - name: pluginVerifier-result - path: ${{ github.workspace }}/build/reports/pluginVerifier + # Build plugin + - name: Build plugin + run: ./gradlew buildPlugin # Prepare plugin archive content for creating artifact - name: Prepare Plugin Artifact @@ -118,11 +98,52 @@ jobs: # Store already-built plugin as an artifact for downloading - name: Upload artifact - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: ${{ steps.artifact.outputs.filename }} path: ./build/distributions/content/*/* + test: + name: Test + needs: [ build ] + runs-on: ubuntu-latest + steps: + + # Check out current repository + - name: Fetch Sources + uses: actions/checkout@v4 + + # Set up Java environment for the next steps + - name: Setup Java + uses: actions/setup-java@v4 + with: + distribution: zulu + java-version: 11 + + # Setup Gradle + - name: Setup Gradle + uses: gradle/actions/setup-gradle@v3 + with: + gradle-home-cache-cleanup: true + + # Run tests + - name: Run Tests + run: ./gradlew check + + # Collect Tests Result of failed tests + - name: Collect Tests Result + if: ${{ failure() }} + uses: actions/upload-artifact@v4 + with: + name: tests-result + path: ${{ github.workspace }}/build/reports/tests + + # Upload the Kover report to CodeCov + - name: Upload Code Coverage Report + uses: codecov/codecov-action@v4 + with: + files: ${{ github.workspace }}/build/reports/kover/report.xml + # Run Qodana inspections and provide report inspectCode: name: Inspect code @@ -143,21 +164,71 @@ jobs: # Check out current repository - name: Fetch Sources - uses: actions/checkout@v3 + uses: actions/checkout@v4 # Set up Java environment for the next steps - name: Setup Java - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: zulu java-version: 17 # Run Qodana inspections - name: Qodana - Code Inspection - uses: JetBrains/qodana-action@v2023.2.1 + uses: JetBrains/qodana-action@v2023.3.1 with: cache-default-branch-only: true + # Run plugin structure verification along with IntelliJ Plugin Verifier + verify: + name: Verify plugin + needs: [ build ] + runs-on: ubuntu-latest + steps: + + # Free GitHub Actions Environment Disk Space + - name: Maximize Build Space + uses: jlumbroso/free-disk-space@main + with: + tool-cache: false + large-packages: false + + # Check out current repository + - name: Fetch Sources + uses: actions/checkout@v4 + + # Set up Java environment for the next steps + - name: Setup Java + uses: actions/setup-java@v4 + with: + distribution: zulu + java-version: 11 + + # Setup Gradle + - name: Setup Gradle + uses: gradle/actions/setup-gradle@v3 + with: + gradle-home-cache-cleanup: true + + # Cache Plugin Verifier IDEs + - name: Setup Plugin Verifier IDEs Cache + uses: actions/cache@v4 + with: + path: ${{ needs.build.outputs.pluginVerifierHomeDir }}/ides + key: plugin-verifier-${{ hashFiles('build/listProductsReleases.txt') }} + + # Run Verify Plugin task and IntelliJ Plugin Verifier tool + - name: Run Plugin Verification tasks + run: ./gradlew runPluginVerifier -Dplugin.verifier.home.dir=${{ needs.build.outputs.pluginVerifierHomeDir }} + + # Collect Plugin Verifier Result + - name: Collect Plugin Verifier Result + if: ${{ always() }} + uses: actions/upload-artifact@v4 + with: + name: pluginVerifier-result + path: ${{ github.workspace }}/build/reports/pluginVerifier + # Prepare a draft release for GitHub Releases page for the manual verification # If accepted and published, release workflow would be triggered releaseDraft: @@ -171,7 +242,7 @@ jobs: # Check out current repository - name: Fetch Sources - uses: actions/checkout@v3 + uses: actions/checkout@v4 # Remove old release drafts by using the curl request for the available releases with draft flag - name: Remove Old Release Drafts @@ -194,4 +265,4 @@ jobs: --notes "$(cat << 'EOM' ${{ needs.build.outputs.changelog }} EOM - )" \ No newline at end of file + )"