Skip to content

Commit 90e9746

Browse files
committed
[KYUUBI #1729] Extract java lint workflow to a single yml and disable it in other jobs
<!-- Thanks for sending a pull request! Here are some tips for you: 1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html 2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'. 3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'. --> ### _Why are the changes needed?_ <!-- Please clarify why the changes are needed. For instance, 1. If you add a feature, you can talk about the use case of it. 2. If you fix a bug, you can clarify why it is a bug. --> quick fail on lint issue, no need to wait unit test ### _How was this patch tested?_ - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible - [ ] Add screenshots for manual tests if appropriate - [ ] [Run test](https://kyuubi.readthedocs.io/en/latest/develop_tools/testing.html#running-tests) locally before make a pull request Closes #1729 from yaooqinn/javalint. Closes #1729 f5f1acd [Kent Yao] Merge branch 'master' into javalint 5b774f0 [Kent Yao] Merge branch 'master' into javalint 6cbd5c6 [Kent Yao] Merge branch 'master' into javalint cc515a6 [Kent Yao] Extract java lint workflow to a single yml and disable it in other jobs Authored-by: Kent Yao <yao@apache.org> Signed-off-by: Kent Yao <yao@apache.org>
1 parent 77f8604 commit 90e9746

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

.github/workflows/master.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ jobs:
7878
${{ runner.os }}-maven-io-
7979
- name: Build with Maven
8080
run: >-
81-
./build/mvn clean install -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -V
81+
./build/mvn clean install -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -Dspotless.check.skip -V
8282
-Pspark-${{ matrix.spark }} -Pspark-hadoop-${{ matrix.spark-hadoop }} ${{ matrix.profiles }}
8383
- name: Code coverage
8484
if: ${{ matrix.codecov == 'true' }}
@@ -136,7 +136,7 @@ jobs:
136136
${{ runner.os }}-maven-io-
137137
- name: Run TPC-DS Tests
138138
run: >-
139-
./build/mvn clean install -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -V
139+
./build/mvn clean install -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -Dspotless.check.skip -V
140140
-pl kyuubi-server -am
141141
-Pspark-3.1
142142
-Dmaven.plugin.scalatest.exclude.tags=''
@@ -177,7 +177,7 @@ jobs:
177177
run: kubectl get pods
178178
- name: integration tests
179179
run: >-
180-
./build/mvn clean install -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -V
180+
./build/mvn clean install -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -Dspotless.check.skip -V
181181
-pl kubernetes/integration-tests -am
182182
-Pkubernetes
183183
-Dtest=none -DwildcardSuites=org.apache.kyuubi.kubernetes.test

.github/workflows/style.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ name: Style check
1717
# limitations under the License.
1818
#
1919

20-
# This GitHub workflow checks Apache License v2.0 Header is added if needed
20+
# This GitHub workflow checks style & dependency issues.
2121

2222

2323
on:
@@ -30,6 +30,10 @@ jobs:
3030
linter:
3131
name: Style and Dep check
3232
runs-on: ubuntu-20.04
33+
strategy:
34+
matrix:
35+
profiles:
36+
- '-Ptpcds -Pspark-block-cleaner -Pkubernetes -Pspark-3.1 -Pspark-3.2'
3337
steps:
3438
- uses: actions/checkout@v2.3.5
3539
- name: Setup JDK 8
@@ -40,8 +44,9 @@ jobs:
4044
- name: Server dependency check
4145
run: build/dependency.sh
4246
- name: Scalastyle with Maven
43-
run: build/mvn scalastyle:check -Ptpcds -Pspark-block-cleaner -Pkubernetes -Pspark-3.1 -Pspark-3.2
47+
run: build/mvn scalastyle:check ${{ matrix.profiles }}
4448
- name: Upload scalastyle report
4549
if: failure()
4650
run: for log in `find * -name "scalastyle-output.xml"`; do echo "=========$log========="; grep "error" $log; done
47-
51+
- name: JavaStyle with Maven
52+
run: build/mvn spotless:check ${{ matrix.profiles }}

0 commit comments

Comments
 (0)