You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ha...@apache.org on 2021/02/23 03:18:48 UTC
[iotdb] branch master updated: move sonar and coverall as seperate
actions; merge Linux and Mac actions into one file (#2713)
This is an automated email from the ASF dual-hosted git repository.
haonan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git
The following commit(s) were added to refs/heads/master by this push:
new ca40856 move sonar and coverall as seperate actions; merge Linux and Mac actions into one file (#2713)
ca40856 is described below
commit ca408565eb609c00fd3d1497884f56a2a3990459
Author: Xiangdong Huang <hx...@apache.org>
AuthorDate: Tue Feb 23 11:18:27 2021 +0800
move sonar and coverall as seperate actions; merge Linux and Mac actions into one file (#2713)
---
.github/workflows/{main-mac.yml => main-unix.yml} | 9 +++++----
.../{main-linux.yml => sonar-coveralls.yml} | 21 ++++++---------------
2 files changed, 11 insertions(+), 19 deletions(-)
diff --git a/.github/workflows/main-mac.yml b/.github/workflows/main-unix.yml
similarity index 84%
rename from .github/workflows/main-mac.yml
rename to .github/workflows/main-unix.yml
index 00c01cd..a8bb4a0 100644
--- a/.github/workflows/main-mac.yml
+++ b/.github/workflows/main-unix.yml
@@ -1,7 +1,7 @@
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
-name: Main Mac
+name: Main Mac and Linux
on:
push:
@@ -26,8 +26,9 @@ jobs:
fail-fast: false
max-parallel: 20
matrix:
- java: [8, 11]
- runs-on: macos-latest
+ java: [ 8, 11 ]
+ os: [ ubuntu-latest, macos-latest ]
+ runs-on: ${{ matrix.os}}
steps:
- uses: actions/checkout@v2
@@ -45,4 +46,4 @@ jobs:
run: mvn -B apache-rat:check -P client-cpp -P site -P code-coverage
- name: IT/UT Test
shell: bash
- run: mvn -B clean post-integration-test -Dtest.port.closed=true
+ run: mvn -B clean post-integration-test -Dtest.port.closed=true
diff --git a/.github/workflows/main-linux.yml b/.github/workflows/sonar-coveralls.yml
similarity index 69%
rename from .github/workflows/main-linux.yml
rename to .github/workflows/sonar-coveralls.yml
index c1720ce..2bee2bc 100644
--- a/.github/workflows/main-linux.yml
+++ b/.github/workflows/sonar-coveralls.yml
@@ -1,9 +1,7 @@
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
-name: Main Linux
-# Main Unix is quite different with Mac and Win Github Action.
-# It consists of not only the UT/IT, but also code coverage and sonar report.
+name: Sonar-Coveralls(Ignore this on folk Repos)
on:
push:
@@ -24,31 +22,24 @@ on:
jobs:
ubuntu:
- strategy:
- fail-fast: false
- max-parallel: 20
- matrix:
- java: [8, 11, 15]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- - name: Set up JDK ${{ matrix.java }}
+ - name: Set up JDK 11
uses: actions/setup-java@v1
with:
- java-version: ${{ matrix.java }}
+ java-version: 11
- name: Cache Maven packages
uses: actions/cache@v2
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2-
- - name: Check Apache Rat
- run: mvn -B apache-rat:check -P client-cpp -P site -P code-coverage
- name: IT/UT Test
- run: mvn -B clean post-integration-test -Dtest.port.closed=true -Pcode-coverage
+ run: mvn -B clean post-integration-test -Dtest.port.closed=true -Pcode-coverage
- name: Code Coverage (Coveralls)
- if: ${{ success() && matrix.java == '11' && github.repository == 'apache/iotdb'}}
+ if: ${{ success() && github.repository == 'apache/iotdb'}}
run: |
mvn -B post-integration-test -Pcode-coverage -pl code-coverage
mvn -B coveralls:report \
@@ -58,7 +49,7 @@ jobs:
-DrepoToken=${{ secrets.COVERALL_TOKEN }} \
-Pcode-coverage
- name: SonarCloud Report
- if: ${{ success() && matrix.java == '11' && github.repository == 'apache/iotdb'}}
+ if: ${{ success() && github.repository == 'apache/iotdb'}}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONARCLOUD_TOKEN }}