Browse Source

feat(ci): define workspace for rust-cache, improving cache key (#5559)

Lucas Fernandes Nogueira 2 years ago
parent
commit
1aba1780de

+ 1 - 1
.github/workflows/artifacts-updater.yml

@@ -45,7 +45,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           workspaces: |
-            .
+            core -> ../target
             tooling/cli
 
       - name: build and install cli.rs

+ 1 - 1
.github/workflows/bench.yml

@@ -55,7 +55,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           workspaces: |
-            .
+            core -> ../target
             tooling/bench/tests
 
       - name: run benchmarks

+ 2 - 0
.github/workflows/check-generated-files.yml

@@ -70,6 +70,8 @@ jobs:
           sudo apt-get install -y libgtk-3-dev
 
       - uses: Swatinem/rust-cache@v2
+        with:
+          workspaces: core -> ../target
 
       - name: generate schema.json
         uses: actions-rs/cargo@v1

+ 1 - 1
.github/workflows/covector-version-or-publish.yml

@@ -35,7 +35,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           workspaces: |
-            .
+            core -> ../target
             tooling/cli
 
       - name: build CLI

+ 2 - 0
.github/workflows/lint-fmt-core.yml

@@ -72,6 +72,8 @@ jobs:
           components: clippy
 
       - uses: Swatinem/rust-cache@v2
+        with:
+          workspaces: core -> ../target
 
       - uses: actions-rs/clippy-check@v1
         with:

+ 2 - 0
.github/workflows/test-core.yml

@@ -65,6 +65,8 @@ jobs:
           sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
 
       - uses: Swatinem/rust-cache@v2
+        with:
+          workspaces: core -> ../target
 
       - name: test
         run: |

+ 1 - 1
.github/workflows/udeps.yml

@@ -142,7 +142,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           workspaces: |
-            .
+            core -> ../target
             tooling/cli
             tooling/bundler