Skip to content
This repository was archived by the owner on Dec 19, 2023. It is now read-only.

Commit 68b071c

Browse files
committed
chore: update pr actions to include google code format verification
1 parent 10a4744 commit 68b071c

File tree

1 file changed

+32
-4
lines changed

1 file changed

+32
-4
lines changed

.github/workflows/pull-request.yml

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,34 @@ jobs:
1010
steps:
1111
- uses: actions/checkout@v2
1212
- uses: gradle/wrapper-validation-action@v1
13+
14+
verify-google-java-format:
15+
name: Google Java Format Verification
16+
runs-on: ubuntu-latest
17+
needs: validation
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@v2
21+
- name: Setup Java
22+
uses: actions/setup-java@v2
23+
with:
24+
distribution: 'zulu'
25+
java-version: 15
26+
- name: Cache Gradle
27+
uses: actions/cache@v2
28+
env:
29+
java-version: 15
30+
with:
31+
path: |
32+
~/.gradle/caches
33+
~/.gradle/wrapper
34+
key: ${{ runner.os }}-${{ env.java-version }}-gradle-${{ hashFiles('**/*.gradle*') }}
35+
restore-keys: ${{ runner.os }}-${{ env.java-version }}-gradle-
36+
- name: Make gradlew executable
37+
run: chmod +x ./gradlew
38+
- name: Gradle Check
39+
run: ./gradlew --info verifyGoogleJavaFormat
40+
1341
test:
1442
name: Test run
1543
strategy:
@@ -36,18 +64,18 @@ jobs:
3664
~/.gradle/caches
3765
~/.gradle/wrapper
3866
key: ${{ runner.os }}-${{ env.java-version }}-gradle-${{ hashFiles('**/*.gradle*') }}
39-
restore-keys: |
40-
${{ runner.os }}-${{ env.java-version }}-gradle-
67+
restore-keys: ${{ runner.os }}-${{ env.java-version }}-gradle-
4168
- name: Make gradlew executable (non-Windows only)
4269
if: matrix.os != 'windows-latest'
4370
run: chmod +x ./gradlew
4471
- name: Gradle Check (non-Windows)
4572
if: matrix.os != 'windows-latest'
46-
run: ./gradlew --info check
73+
run: ./gradlew --info check -x verifyGoogleJavaFormat
4774
- name: Gradle Check (Windows)
4875
if: matrix.os == 'windows-latest'
4976
shell: cmd
50-
run: gradlew --info check
77+
run: gradlew --info check -x verifyGoogleJavaFormat
78+
5179
build:
5280
name: Sonar analysis
5381
needs: validation

0 commit comments

Comments
 (0)