Merge GH actions in one file.
authorJérôme Benoit <jerome.benoit@sap.com>
Sat, 21 Aug 2021 18:26:42 +0000 (20:26 +0200)
committerJérôme Benoit <jerome.benoit@sap.com>
Sat, 21 Aug 2021 18:26:42 +0000 (20:26 +0200)
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
.github/workflows/ci.yml [moved from .github/workflows/build.yml with 61% similarity]
.github/workflows/lint.yml [deleted file]
.github/workflows/unit-tests.yml [deleted file]

similarity index 61%
rename from .github/workflows/build.yml
rename to .github/workflows/ci.yml
index 9390bb5cdcf33befaaf0838cce2707658e0deb68..97fe7e9edccece441d0168df73fd8f85cdde5acd 100644 (file)
@@ -1,4 +1,4 @@
-name: Build CI
+name: CI
 on:
   push:
     branches:
@@ -15,6 +15,8 @@ jobs:
         node-version: [14.x]
     steps:
     - uses: actions/checkout@v2
+      with:
+        fetch-depth: 0  # Shallow clones should be disabled for a better relevancy of analysis
     - name: Use Node.js ${{ matrix.node-version }}
       uses: actions/setup-node@v2
       with:
@@ -23,7 +25,16 @@ jobs:
       run: npm ci
     - name: npm run build
       run: npm run build
-  docker:
+    - name: npm run lint
+      run: npm run lint
+    - name: npm test
+      run: npm test
+    - name: SonarCloud Scan
+      uses: SonarSource/sonarcloud-github-action@master
+      env:
+        GITHUB_TOKEN: ${{ secrets.USER_TOKEN }}  # Needed to get PR information, if any
+        SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
+  build-docker:
     runs-on: ubuntu-latest
     steps:
     - uses: actions/checkout@v2
@@ -34,16 +45,3 @@ jobs:
       run: |
         cd docker
         make SUBMODULES_INIT=false
-  sonarcloud:
-    name: SonarCloud
-    runs-on: ubuntu-latest
-    steps:
-      - uses: actions/checkout@v2
-        with:
-          fetch-depth: 0  # Shallow clones should be disabled for a better relevancy of analysis
-      - name: SonarCloud Scan
-        uses: SonarSource/sonarcloud-github-action@master
-        env:
-          GITHUB_TOKEN: ${{ secrets.USER_TOKEN }}  # Needed to get PR information, if any
-          SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
-
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
deleted file mode 100644 (file)
index d49773c..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-name: Lint CI
-
-on:
-  # push:
-  #   branches:
-  #     - master
-  pull_request:
-    types: [opened, synchronize, reopened]
-    branches:
-      - master
-
-jobs:
-  lint:
-    runs-on: ubuntu-latest
-
-    strategy:
-      matrix:
-        node-version: [14.x]
-
-    steps:
-    - uses: actions/checkout@v2
-    - name: Use Node.js ${{ matrix.node-version }}
-      uses: actions/setup-node@v2
-      with:
-        node-version: ${{ matrix.node-version }}
-    - name: npm install
-      run: npm ci
-    - name: npm run lint
-      run: npm run lint
diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml
deleted file mode 100644 (file)
index 4089d4c..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-name: Unit Tests CI
-
-on:
-  push:
-    branches:
-      - master
-  pull_request:
-    types: [opened, synchronize, reopened]
-    branches:
-      - master
-
-jobs:
-  unit-tests:
-    runs-on: ubuntu-latest
-    strategy:
-      matrix:
-        node-version: [14.x]
-    steps:
-    - uses: actions/checkout@v2
-    - name: Use Node.js ${{ matrix.node-version }}
-      uses: actions/setup-node@v2
-      with:
-        node-version: ${{ matrix.node-version }}
-    - name: npm install
-      run: npm ci
-    # - name: npm run build
-    #   run: npm run build
-    - name: npm test
-      run: npm test
-