From ab94dea2fe0358c700040ab24b83cd81f2f1bda1 Mon Sep 17 00:00:00 2001 From: harveymmaunders Date: Fri, 13 Dec 2024 14:44:16 +0000 Subject: [PATCH 1/4] Java dependabot and ci actions --- .github/dependabot.yml | 10 ++++++++++ .github/workflows/java-ci.yml | 23 +++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/java-ci.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..9436b95 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,10 @@ +version: 2 +updates: + - package-ecosystem: "gradle" + directory: "/client-samples/java/rest" + schedule: + interval: "weekly" + day: "monday" + time: "08:00" + commit-message: + prefix: "gradle" \ No newline at end of file diff --git a/.github/workflows/java-ci.yml b/.github/workflows/java-ci.yml new file mode 100644 index 0000000..9486016 --- /dev/null +++ b/.github/workflows/java-ci.yml @@ -0,0 +1,23 @@ +name: Java CI +on: + pull_request: + branches: [ "main" ] +jobs: + build: + runs-on: ubuntu-latest + permissions: + contents: read + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Set up JDK 17 + uses: actions/setup-java@v4 + with: + java-version: '17' + distribution: 'temurin' + - name: Setup Gradle + uses: gradle/actions/setup-gradle@af1da67850ed9a4cedd57bfd976089dd991e2582 + - name: Gradle Build + run: ./gradlew build + - name: Gradle Test + run: ./gradlew test From 3cf041a7391654af215eed570be840c012a1d4ca Mon Sep 17 00:00:00 2001 From: harveymmaunders Date: Fri, 13 Dec 2024 15:00:00 +0000 Subject: [PATCH 2/4] Updated working directory --- .github/workflows/java-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/java-ci.yml b/.github/workflows/java-ci.yml index 9486016..e54a1e0 100644 --- a/.github/workflows/java-ci.yml +++ b/.github/workflows/java-ci.yml @@ -1,3 +1,6 @@ +defaults: + run: + working-directory: ./client-samples/java/rest name: Java CI on: pull_request: From 6394a4dbd990180bba733057939148a552981e3e Mon Sep 17 00:00:00 2001 From: harveymmaunders Date: Fri, 13 Dec 2024 15:06:58 +0000 Subject: [PATCH 3/4] Updated java CI on --- .github/workflows/java-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/java-ci.yml b/.github/workflows/java-ci.yml index e54a1e0..74c48a0 100644 --- a/.github/workflows/java-ci.yml +++ b/.github/workflows/java-ci.yml @@ -3,6 +3,8 @@ defaults: working-directory: ./client-samples/java/rest name: Java CI on: + push: + branches: [ "main" ] pull_request: branches: [ "main" ] jobs: From 097ab535a160e9964374a9fe6ac1254fef2c596e Mon Sep 17 00:00:00 2001 From: harveymmaunders Date: Fri, 13 Dec 2024 15:26:19 +0000 Subject: [PATCH 4/4] Removed hash version for gradle actions --- .github/workflows/java-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/java-ci.yml b/.github/workflows/java-ci.yml index 74c48a0..714f809 100644 --- a/.github/workflows/java-ci.yml +++ b/.github/workflows/java-ci.yml @@ -21,7 +21,7 @@ jobs: java-version: '17' distribution: 'temurin' - name: Setup Gradle - uses: gradle/actions/setup-gradle@af1da67850ed9a4cedd57bfd976089dd991e2582 + uses: gradle/actions/setup-gradle@v4 - name: Gradle Build run: ./gradlew build - name: Gradle Test