GH Actions: Cancel builds on push, remove redundant mac OS build. (#4779)
authorAina Niemetz <aina.niemetz@gmail.com>
Tue, 21 Jul 2020 17:50:54 +0000 (10:50 -0700)
committerGitHub <noreply@github.com>
Tue, 21 Jul 2020 17:50:54 +0000 (10:50 -0700)
.github/workflows/ci.yml

index e9587e2e6308e4ec991e42ffce61cab380cbf6da..74c65cfac778a9fe7ede58e98993c9552764522f 100644 (file)
@@ -2,8 +2,15 @@ on: [push, pull_request]
 name: CI
 
 jobs:
-  build:
+  cancel:
+    runs-on: ubuntu-latest
+    steps:
+      - name: cancel-previous-runs
+        uses: styfle/cancel-workflow-action@0.4.1
+        with:
+          access_token: ${{ github.token }}
 
+  build:
     strategy:
       matrix:
         os: [ubuntu-latest, macos-latest]
@@ -14,6 +21,14 @@ jobs:
           debug-cln
         ]
 
+        exclude:
+          - name: production-clang
+            os: macos-latest
+          - name: debug
+            os: macos-latest
+          - name: debug-cln
+            os: macos-latest
+
         include:
           - name: production
             config: production --all-bindings --lfsc --editline
@@ -26,14 +41,17 @@ jobs:
             cache-key: production-clang
             check-examples: true
             env: CC=clang CXX=clang++
+            os: ubuntu-latest
 
           - name: debug
             config: debug --symfpu --lfsc --no-debug-symbols --editline
             cache-key: debug
+            os: ubuntu-latest
 
           - name: debug-cln
             config: debug --symfpu --cln --gpl --no-debug-symbols --no-proofs
             cache-key: debug-cln
+            os: ubuntu-latest
 
     name: ${{ matrix.os }}:${{ matrix.name }}
     runs-on: ${{ matrix.os }}