diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a70eef4..a5efe6c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,23 +23,26 @@ jobs: strategy: matrix: os: [ubuntu-latest] - scala: [2.12.18, 2.13.11] - java: [temurin@11] + scala: [3.3.3] + java: [temurin@17] runs-on: ${{ matrix.os }} steps: - name: Checkout current branch (full) - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 0 - - name: Setup Java (temurin@11) - if: matrix.java == 'temurin@11' - uses: actions/setup-java@v3 + - name: Setup Java (temurin@17) + if: matrix.java == 'temurin@17' + uses: actions/setup-java@v4 with: distribution: temurin - java-version: 11 + java-version: 17 cache: sbt + - name: Setup sbt + uses: sbt/setup-sbt@v1 + - name: Check that workflows are up to date run: sbt '++ ${{ matrix.scala }}' githubWorkflowCheck @@ -50,7 +53,7 @@ jobs: run: tar cf targets.tar target project/target - name: Upload target directories - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: target-${{ matrix.os }}-${{ matrix.scala }}-${{ matrix.java }} path: targets.tar @@ -62,39 +65,32 @@ jobs: strategy: matrix: os: [ubuntu-latest] - scala: [2.13.11] - java: [temurin@11] + scala: [3.3.3] + java: [temurin@17] runs-on: ${{ matrix.os }} steps: - name: Checkout current branch (full) - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 0 - - name: Setup Java (temurin@11) - if: matrix.java == 'temurin@11' - uses: actions/setup-java@v3 + - name: Setup Java (temurin@17) + if: matrix.java == 'temurin@17' + uses: actions/setup-java@v4 with: distribution: temurin - java-version: 11 + java-version: 17 cache: sbt - - name: Download target directories (2.12.18) - uses: actions/download-artifact@v3 - with: - name: target-${{ matrix.os }}-2.12.18-${{ matrix.java }} - - - name: Inflate target directories (2.12.18) - run: | - tar xf targets.tar - rm targets.tar + - name: Setup sbt + uses: sbt/setup-sbt@v1 - - name: Download target directories (2.13.11) - uses: actions/download-artifact@v3 + - name: Download target directories (3.3.3) + uses: actions/download-artifact@v4 with: - name: target-${{ matrix.os }}-2.13.11-${{ matrix.java }} + name: target-${{ matrix.os }}-3.3.3-${{ matrix.java }} - - name: Inflate target directories (2.13.11) + - name: Inflate target directories (3.3.3) run: | tar xf targets.tar rm targets.tar diff --git a/.github/workflows/clean.yml b/.github/workflows/clean.yml index 547aaa4..bfc865d 100644 --- a/.github/workflows/clean.yml +++ b/.github/workflows/clean.yml @@ -17,6 +17,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - name: Delete artifacts + shell: bash {0} run: | # Customize those three lines with your repository and credentials: REPO=${GITHUB_API_URL}/repos/${{ github.repository }} @@ -25,7 +26,7 @@ jobs: ghapi() { curl --silent --location --user _:$GITHUB_TOKEN "$@"; } # A temporary file which receives HTTP response headers. - TMPFILE=/tmp/tmp.$$ + TMPFILE=$(mktemp) # An associative array, key: artifact name, value: number of artifacts of that name. declare -A ARTCOUNT