From 6813a882b55b5d8a6ead44b894463d9475bbd183 Mon Sep 17 00:00:00 2001 From: "Erik C. Thauvin" Date: Sat, 8 May 2021 23:28:06 -0700 Subject: [PATCH] Added more CIs --- .github/workflows/gradle.yml | 18 ++++++++++++++++++ .gitlab-ci.yml | 31 +++++++++++++++++++++++++++++++ bitbucket-pipelines.yml | 9 +++++++++ 3 files changed, 58 insertions(+) create mode 100644 .github/workflows/gradle.yml create mode 100644 .gitlab-ci.yml create mode 100644 bitbucket-pipelines.yml diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml new file mode 100644 index 0000000..b171473 --- /dev/null +++ b/.github/workflows/gradle.yml @@ -0,0 +1,18 @@ +name: Java CI with Gradle + +on: [push, pull_request, workflow_dispatch] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Set up JDK 11 + uses: actions/setup-java@v1 + with: + java-version: 11 + - name: Grant execute permission for gradlew + run: chmod +x gradlew + - name: Test with Gradle + run: ./gradlew check diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..26820aa --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,31 @@ +image: gradle:alpine + +variables: + GRADLE_OPTS: "-Dorg.gradle.daemon=false" + +before_script: + - export GRADLE_USER_HOME=`pwd`/.gradle + +stages: + - build + - test + +build: + stage: build + script: ./gradlew --build-cache assemble + cache: + key: "$CI_COMMIT_REF_NAME" + policy: push + paths: + - build + - .gradle + +test: + stage: test + script: ./gradlew check + cache: + key: "$CI_COMMIT_REF_NAME" + policy: pull + paths: + - build + - .gradle diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml new file mode 100644 index 0000000..219c29f --- /dev/null +++ b/bitbucket-pipelines.yml @@ -0,0 +1,9 @@ +image: openjdk:11 + +pipelines: + default: + - step: + caches: + - gradle + script: + - bash ./gradlew check