Skip to content

Commit

Permalink
Update for 243 realease - Switching to PackageApiClientService provid…
Browse files Browse the repository at this point in the history
…ed by the platform (#194)

* revamped build logic, use ApiClient as provided by the platform

* Update dependencies and refactor UI components

* update intellij target version

* Update Jewel version and add PropertyMapping annotations

* Add coroutine support and refactor Gradle module construction

* Remove unnecessary serialization annotations

* Update IntelliJ version and remove unused @serializable annotation

* Upgrade to JDK 17 in GitHub Actions workflow

* Add ExperimentalPathApi annotations in tests

* Remove TrustKotlinGradlePluginPatch from workflow

Deleted the TrustKotlinGradlePluginPatch scripts and their usage in the GitHub Actions workflow. This simplifies the test step configuration and removes the conditional patching mechanism when tests fail.
  • Loading branch information
fscarponi authored Nov 7, 2024
1 parent cd29c6d commit ff2b0ac
Show file tree
Hide file tree
Showing 57 changed files with 233 additions and 21,879 deletions.
99 changes: 0 additions & 99 deletions .github/workflows/TrustKotlinGradlePluginPatch.kt

This file was deleted.

85 changes: 0 additions & 85 deletions .github/workflows/TrustKotlinGradlePluginPatch.main.kts

This file was deleted.

97 changes: 13 additions & 84 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ jobs:
with:
submodules: true
- uses: gradle/gradle-build-action@v3
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: 11
java-version: 17
distribution: 'temurin'
- name: Run GRADLE tests
continue-on-error: true
Expand All @@ -39,22 +39,7 @@ jobs:
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.GradleProjectTest"
- name: Patch IDE config files
if: steps.simple-build.outcome == 'failure'
run: kotlinc -script ./.github/workflows/TrustKotlinGradlePluginPatch.main.kts
- name: Run GRADLE tests PATCHED
if: steps.simple-build.outcome == 'failure'
env:
KMP: true
GRADLE_VERSION: ${{ matrix.gradle-version }}
GRADLE_ENTERPRISE_KEY: ${{ secrets.GRADLE_ENTERPRISE_KEY }}
JAVA_VERSION: ${{matrix.jdk-version}}
SPACE_INTELLIJ_NIGHTLIES_TOKEN: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_TOKEN }}
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.GradleProjectTest"
run: ./gradlew :plugin:test --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.GradleProjectTest"
- name: Upload test result
if: always()
uses: actions/upload-artifact@v4
Expand All @@ -73,10 +58,10 @@ jobs:
with:
submodules: true
- uses: gradle/gradle-build-action@v3
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: 11
java-version: 17
distribution: 'temurin'
- name: Run MAVEN tests
id: simple-build
Expand All @@ -89,21 +74,7 @@ jobs:
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.MavenProjectTest"
- name: Patch IDE config files
if: steps.simple-build.outcome == 'failure'
run: kotlinc -script ./.github/workflows/TrustKotlinGradlePluginPatch.main.kts
- name: Run MAVEN tests Patched
if: steps.simple-build.outcome == 'failure'
env:
KMP: true
GRADLE_ENTERPRISE_KEY: ${{ secrets.GRADLE_ENTERPRISE_KEY }}
JAVA_VERSION: ${{matrix.jdk-version}}
SPACE_INTELLIJ_NIGHTLIES_TOKEN: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_TOKEN }}
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.MavenProjectTest"
run: ./gradlew :plugin:test --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.MavenProjectTest"
- name: Upload test result
if: always()
uses: actions/upload-artifact@v4
Expand All @@ -125,10 +96,10 @@ jobs:
with:
submodules: true
- uses: gradle/gradle-build-action@v3
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: 11
java-version: 17
distribution: 'temurin'
- name: Run KMP tests
id: simple-build
Expand All @@ -142,22 +113,7 @@ jobs:
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.KMPGradleProjectTest"
- name: Patch IDE config files
if: steps.simple-build.outcome == 'failure'
run: kotlinc -script ./.github/workflows/TrustKotlinGradlePluginPatch.main.kts
- name: Run KMP tests
if: steps.simple-build.outcome == 'failure'
env:
KMP: true
GRADLE_VERSION: ${{ matrix.gradle-version }}
GRADLE_ENTERPRISE_KEY: ${{ secrets.GRADLE_ENTERPRISE_KEY }}
JAVA_VERSION: ${{matrix.jdk-version}}
SPACE_INTELLIJ_NIGHTLIES_TOKEN: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_TOKEN }}
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.KMPGradleProjectTest"
run: ./gradlew :plugin:test --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.KMPGradleProjectTest"
- name: Upload test result
if: always()
uses: actions/upload-artifact@v4
Expand All @@ -181,10 +137,10 @@ jobs:
with:
submodules: true
- uses: gradle/gradle-build-action@v3
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: 11
java-version: 17
distribution: 'temurin'
- name: Run VERSION CATALOG tests
continue-on-error: true
Expand All @@ -199,21 +155,6 @@ jobs:
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.CatalogProjectTest"
- name: Patch IDE config files
if: steps.simple-build.outcome == 'failure'
run: kotlinc -script ./.github/workflows/TrustKotlinGradlePluginPatch.main.kts
- name: Run VERSION CATALOG tests PATCHED
if: steps.simple-build.outcome == 'failure'
env:
KMP: true
GRADLE_VERSION: ${{ matrix.gradle-version }}
GRADLE_ENTERPRISE_KEY: ${{ secrets.GRADLE_ENTERPRISE_KEY }}
JAVA_VERSION: ${{matrix.jdk-version}}
SPACE_INTELLIJ_NIGHTLIES_TOKEN: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_TOKEN }}
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:test --continue --tests "com.jetbrains.packagesearch.plugin.tests.end2end.projectservice.CatalogProjectTest"
- name: Upload test result
if: always()
uses: actions/upload-artifact@v4
Expand All @@ -228,10 +169,10 @@ jobs:
with:
submodules: true
- uses: gradle/gradle-build-action@v3
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: 11
java-version: 17
distribution: 'temurin'
- name: Run UNIT tests
id: simple-build
Expand All @@ -243,15 +184,3 @@ jobs:
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:utils:test
- name: Patch IDE config files
if: steps.simple-build.outcome == 'failure'
run: kotlinc -script ./.github/workflows/TrustKotlinGradlePluginPatch.main.kts
- name: Run UNIT tests
if: steps.simple-build.outcome == 'failure'
env:
GRADLE_ENTERPRISE_KEY: ${{ secrets.GRADLE_ENTERPRISE_KEY }}
SPACE_INTELLIJ_NIGHTLIES_TOKEN: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_TOKEN }}
SPACE_INTELLIJ_NIGHTLIES_USERNAME: ${{ secrets.SPACE_INTELLIJ_NIGHTLIES_USERNAME }}
SPACE_PACKAGE_SEARCH_TOKEN: ${{ secrets.SPACE_PACKAGE_SEARCH_TOKEN }}
SPACE_PACKAGE_SEARCH_USERNAME: ${{ secrets.SPACE_PACKAGE_SEARCH_USERNAME }}
run: ./gradlew :plugin:utils:test
3 changes: 1 addition & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,14 @@ plugins {
alias(packageSearchCatalog.plugins.shadow) apply false
alias(packageSearchCatalog.plugins.dokka) apply false
alias(packageSearchCatalog.plugins.kotlin.jvm) apply false
alias(packageSearchCatalog.plugins.kotlin.plugin.serialization) apply false
alias(packageSearchCatalog.plugins.kotlin.plugin.compose) apply false
alias(packageSearchCatalog.plugins.compose.desktop) apply false
alias(packageSearchCatalog.plugins.kotlinter) apply false
}

allprojects {
group = "org.jetbrains.packagesearch"
val baseVersion = "242-SNAPSHOT"
val baseVersion = "243-SNAPSHOT"

version = when (val ref = getenv("GITHUB_REF")) {
null -> baseVersion
Expand Down
1 change: 1 addition & 0 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ dependencies {
implementation(libs.poet.kotlin)
implementation(libs.flexmark)
implementation(libs.gradle.intellij.platform.plugin)
implementation(libs.kotlin.serialization.gradle.plugin)
}
Loading

0 comments on commit ff2b0ac

Please sign in to comment.