Skip to content

Commit

Permalink
build(github): introduce gradle checks
Browse files Browse the repository at this point in the history
  • Loading branch information
jimirocks committed Feb 4, 2024
1 parent 2eb0311 commit 8108a7b
Show file tree
Hide file tree
Showing 4 changed files with 68 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
name: Check

on:
workflow_call:
inputs:
projectDir:
description: "project to be checked (path to project directory)"
type: string
required: false
default: '.'

jobs:
gradle-check:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'

- name: Set up Gradle
uses: gradle/actions/setup-gradle@v3

- name: Check with Gradle
run: ./gradlew -p ${{ inputs.projectDir }} clean check
13 changes: 13 additions & 0 deletions .github/workflows/java-example-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: Java Example check

on:
pull_request:
paths:
- 'examples/java/**'

jobs:
call-check:
uses: ./.github/workflows/check.yml
with:
projectDir: 'examples/java'
13 changes: 13 additions & 0 deletions .github/workflows/kotlin-example-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: Kotlin Example check

on:
pull_request:
paths:
- 'examples/kotlin/**'

jobs:
call-check:
uses: ./.github/workflows/check.yml
with:
projectDir: 'examples/kotlin'
12 changes: 12 additions & 0 deletions .github/workflows/loxone-client-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
name: Loxone Client Kotlin check

on:
pull_request:
paths:
- '.*gradle.*'
- 'src/**'

jobs:
call-check:
uses: ./.github/workflows/check.yml

0 comments on commit 8108a7b

Please sign in to comment.