From 6649d2b4c4fa0d68c0a257651f99ace8394d3fe2 Mon Sep 17 00:00:00 2001 From: Eugene Yokota Date: Thu, 26 Dec 2024 03:04:27 -0500 Subject: [PATCH] GitHub Actions update --- .github/workflows/ci.yml | 3 ++- .github/workflows/cla.yml | 8 ++++---- project/scripts/check-cla.sh | 17 ----------------- 3 files changed, 6 insertions(+), 22 deletions(-) delete mode 100755 project/scripts/check-cla.sh diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 658fb3f..0dff5a4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,11 +11,12 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: coursier/cache-action@v6 - uses: actions/setup-java@v4 with: distribution: temurin java-version: 8 + cache: sbt + - uses: sbt/setup-sbt@v1 - name: Test # This runs the template with the default parameters, and runs test within the templated app. run: sbt -Dfile.encoding=UTF8 test diff --git a/.github/workflows/cla.yml b/.github/workflows/cla.yml index 52f5eca..c7ec83e 100644 --- a/.github/workflows/cla.yml +++ b/.github/workflows/cla.yml @@ -4,7 +4,7 @@ jobs: check: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 - - run: ./project/scripts/check-cla.sh - env: - AUTHOR: ${{ github.event.pull_request.user.login }} + - name: Check CLA + uses: scala/cla-checker@v1 + with: + author: ${{ github.event.pull_request.user.login }} diff --git a/project/scripts/check-cla.sh b/project/scripts/check-cla.sh deleted file mode 100755 index 8538a27..0000000 --- a/project/scripts/check-cla.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/usr/bin/env bash -set -eux - -AUTHOR=$GITHUB_ACTOR -echo "Pull request submitted by $AUTHOR"; -signed=$(curl -s https://www.lightbend.com/contribute/cla/scala/check/$AUTHOR | jq -r ".signed"); -if [ "$signed" = "true" ] ; then - echo "CLA check for $AUTHOR successful"; -else - echo "CLA check for $AUTHOR failed"; - echo "Please sign the Scala CLA to contribute to the Scala compiler."; - echo "Go to https://www.lightbend.com/contribute/cla/scala and then"; - echo "comment on the pull request to ask for a new check."; - echo ""; - echo "Check if CLA is signed: https://www.lightbend.com/contribute/cla/scala/check/$AUTHOR"; - exit 1; -fi;