diff --git a/.circleci/config.yml b/.circleci/config.yml index c5e20a6..3aabdd8 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,4 +1,8 @@ -version: 2 +version: 2.1 + +orbs: + sdkman: joshdholtz/sdkman@0.2.0 + defaults: &defaults working_directory: ~/repo environment: @@ -9,14 +13,10 @@ defaults: &defaults defaults_bld: &defaults_bld steps: - checkout - - run: - name: Install Kotlin via SDKMAN! - command: | - curl -s "https://get.sdkman.io" | bash - echo sdkman_auto_answer=true > $HOME/.sdkman/etc/config - echo sdkman_auto_selfupdate=true >> $HOME/.sdkman/etc/config - source "$HOME/.sdkman/bin/sdkman-init.sh" - sdk install kotlin 2.0.0 + - sdkman/setup-sdkman + - sdkman/sdkman-install: + candidate: kotlin + version: 2.0.0 - run: name: Download the bld dependencies command: ./bld download diff --git a/.github/workflows/bld.yml b/.github/workflows/bld.yml index 21c09a8..ee69e07 100644 --- a/.github/workflows/bld.yml +++ b/.github/workflows/bld.yml @@ -1,19 +1,20 @@ name: bld-ci -on: [push, pull_request, workflow_dispatch] +on: [ push, pull_request, workflow_dispatch ] jobs: build-bld-project: runs-on: ubuntu-latest env: - COVERAGE_SDK: "17" + COVERAGE_JDK: "17" COVERAGE_KOTLIN: "2.0.0" + KOTLIN_HOME: /usr/share/kotlinc strategy: matrix: - java-version: [17, 21, 22] - kotlin-version: [1.9.24, 2.0.0] + java-version: [ 17, 21, 22 ] + kotlin-version: [ 1.9.24, 2.0.0 ] steps: - name: Checkout source repository @@ -54,7 +55,7 @@ jobs: - name: SonarCloud Scan uses: sonarsource/sonarcloud-github-action@master - if: success() && matrix.java-version == env.COVERAGE_SDK && matrix.kotlin-version == env.COVERAGE_KOTLIN + if: success() && matrix.java-version == env.COVERAGE_JDK && matrix.kotlin-version == env.COVERAGE_KOTLIN env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml index 5951f4b..5fb2237 100644 --- a/bitbucket-pipelines.yml +++ b/bitbucket-pipelines.yml @@ -11,7 +11,7 @@ pipelines: - echo sdkman_auto_answer=true > $HOME/.sdkman/etc/config - echo sdkman_auto_selfupdate=true >> $HOME/.sdkman/etc/config - source "$HOME/.sdkman/bin/sdkman-init.sh" - - sdk install java 17.0.11-tem + - sdk install java 17.0.11-oracle - sdk install kotlin 2.0.0 - source "$HOME/.sdkman/bin/sdkman-init.sh" # Download, compile and test with bld