diff --git a/.circleci/config.yml b/.circleci/config.yml index c5e20a6..cd95a0c 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: @@ -6,26 +10,23 @@ defaults: &defaults TERM: dumb CI_NAME: "CircleCI" -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 - - run: - name: Download the bld dependencies - command: ./bld download - - run: - name: Compile source with bld - command: ./bld compile - - run: - name: Run tests with bld - command: ./bld test +commands: + build_and_test: + steps: + - checkout + - sdkman/setup-sdkman + - sdkman/sdkman-install: + candidate: kotlin + version: 2.0.0 + - run: + name: Download dependencies + command: ./bld download + - run: + name: Compile source + command: ./bld compile + - run: + name: Run tests + command: ./bld test jobs: bld_jdk17: @@ -34,7 +35,8 @@ jobs: docker: - image: cimg/openjdk:17.0 - <<: *defaults_bld + steps: + - build_and_test bld_jdk20: <<: *defaults @@ -42,10 +44,10 @@ jobs: docker: - image: cimg/openjdk:20.0 - <<: *defaults_bld + steps: + - build_and_test workflows: - version: 2 bld: jobs: - bld_jdk17 diff --git a/.github/workflows/bld.yml b/.github/workflows/bld.yml index 21c09a8..dd8f7a1 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: "21" 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/.gitlab-ci.yml b/.gitlab-ci.yml index 14646f3..10b9b0f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,4 +1,4 @@ -image: ubuntu:latest +image: fedora:latest variables: CI_NAME: "GitLab CI" @@ -7,13 +7,13 @@ stages: - test before_script: - - apt-get update -qq && apt-get install -y curl zip + - dnf -qy update && dnf -y install zip - 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 java 17.0.11-tem - - sdk install kotlin 2.0.0 + - sdk install java + - sdk install kotlin - source "$HOME/.sdkman/bin/sdkman-init.sh" test: diff --git a/.idea/libraries/bld.xml b/.idea/libraries/bld.xml index a2969be..2fb5ff0 100644 --- a/.idea/libraries/bld.xml +++ b/.idea/libraries/bld.xml @@ -2,12 +2,12 @@ - + - + diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml index 5951f4b..ace99d2 100644 --- a/bitbucket-pipelines.yml +++ b/bitbucket-pipelines.yml @@ -5,14 +5,14 @@ pipelines: - step: name: Test with bld script: - # Install Java & Kotlin via SDKMAN! + # Install latest Java & Kotlin via SDKMAN! - apt-get update -qq && apt-get install -y curl zip - 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 java 17.0.11-tem - - sdk install kotlin 2.0.0 + - sdk install java + - sdk install kotlin - source "$HOME/.sdkman/bin/sdkman-init.sh" # Download, compile and test with bld - ./bld download diff --git a/lib/bld/bld-wrapper.jar b/lib/bld/bld-wrapper.jar index 8a6c641..f46bb77 100644 Binary files a/lib/bld/bld-wrapper.jar and b/lib/bld/bld-wrapper.jar differ diff --git a/lib/bld/bld-wrapper.properties b/lib/bld/bld-wrapper.properties index 0aa69b0..e9d6ec3 100644 --- a/lib/bld/bld-wrapper.properties +++ b/lib/bld/bld-wrapper.properties @@ -7,4 +7,4 @@ bld.extension-jacoco=com.uwyn.rife2:bld-jacoco-report:0.9.6 bld.extension-kotlin=com.uwyn.rife2:bld-kotlin:1.0.0-SNAPSHOT bld.repositories=MAVEN_LOCAL,MAVEN_CENTRAL,RIFE2_SNAPSHOTS,RIFE2_RELEASES bld.sourceDirectories= -bld.version=1.9.1 +bld.version=2.0.0-SNAPSHOT