Quellcode durchsuchen

combine jobs and add step with conditional (#121)

* combine jobs and add step with conditional

* too many equals
Jacob Bolda vor 5 Jahren
Ursprung
Commit
ebc736070f
1 geänderte Dateien mit 5 neuen und 23 gelöschten Zeilen
  1. 5 23
      .github/workflows/test-on-pr.yml

+ 5 - 23
.github/workflows/test-on-pr.yml

@@ -9,26 +9,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        platform: [macos-latest, windows-latest]
-
-    steps:
-    - uses: actions/checkout@v1
-      with:
-        fetch-depth: 3
-    - name: install stable
-      uses: actions-rs/toolchain@v1
-      with:
-          toolchain: stable
-    - name: build
-      run: |
-           cd ./tauri
-           cargo build
-      env:
-        TAURI_DIST_DIR: ../../test/fixture/dist
-        TAURI_CONFIG_DIR: ../test/fixture/
-
-  build-tauri-ubuntu-latest:
-    runs-on: ubuntu-latest
+        platform: [ubuntu-latest, macos-latest, windows-latest]
 
     steps:
     - uses: actions/checkout@v1
@@ -38,7 +19,8 @@ jobs:
       uses: actions-rs/toolchain@v1
       with:
           toolchain: stable
-    - name: install webkit2gtk
+    - name: install webkit2gtk (ubuntu only)
+      if: matrix.platform == 'ubuntu-latest'
       run: |
            sudo apt-get update
            sudo apt-get install -y webkit2gtk-4.0
@@ -48,7 +30,7 @@ jobs:
            cargo build
       env:
         TAURI_DIST_DIR: ../../test/fixture/dist
-        TAURI_CONFIG_DIR: ../test/fixture
+        TAURI_CONFIG_DIR: ../test/fixture/
 
   build-tauri-cli:
     runs-on: ${{ matrix.platform }}
@@ -88,4 +70,4 @@ jobs:
       run: |
            cd ./cli/tauri.js
            yarn
-           yarn test
+           yarn test