Selaa lähdekoodia

let's see if this works

Dan Korostelev 5 vuotta sitten
vanhempi
commit
6881719b55

+ 14 - 0
.github/workflows/main.yml

@@ -193,7 +193,14 @@ jobs:
           sudo apt-get update -qqy
           sudo apt-get install -qqy ocaml-nox camlp5 opam libpcre3-dev zlib1g-dev libgtk2.0-dev libmbedtls-dev ninja-build neko neko-dev
       
+      - uses: actions/cache@v2
+        id: opam-cache
+        with:
+          path: ~/.opam
+          key: ${{ runner.os }}-${{ hashFiles('opam') }}
+      
       - name: Install OCaml libraries
+        if: steps.opam-cache.outputs.cache-hit != 'true'
         run: |
           set -ex
           opam init # --disable-sandboxing
@@ -260,7 +267,14 @@ jobs:
           brew unlink python@2
           brew bundle --file=tests/Brewfile --no-upgrade
       
+      - uses: actions/cache@v2
+        id: opam-cache
+        with:
+          path: ~/.opam
+          key: ${{ runner.os }}-${{ hashFiles('opam') }}
+      
       - name: Install OCaml libraries
+        if: steps.opam-cache.outputs.cache-hit != 'true'
         run: |
           set -ex
           opam init # --disable-sandboxing

+ 7 - 0
extra/github-actions/build-linux.yml

@@ -6,7 +6,14 @@
     sudo apt-get update -qqy
     sudo apt-get install -qqy ocaml-nox camlp5 opam libpcre3-dev zlib1g-dev libgtk2.0-dev libmbedtls-dev ninja-build neko neko-dev
 
+- uses: actions/cache@v2
+  id: opam-cache
+  with:
+    path: ~/.opam
+    key: ${{ runner.os }}-${{ hashFiles('opam') }}
+
 - name: Install OCaml libraries
+  if: steps.opam-cache.outputs.cache-hit != 'true'
   run: |
     set -ex
     opam init # --disable-sandboxing

+ 7 - 0
extra/github-actions/build-mac.yml

@@ -5,7 +5,14 @@
     brew unlink python@2
     brew bundle --file=tests/Brewfile --no-upgrade
 
+- uses: actions/cache@v2
+  id: opam-cache
+  with:
+    path: ~/.opam
+    key: ${{ runner.os }}-${{ hashFiles('opam') }}
+
 - name: Install OCaml libraries
+  if: steps.opam-cache.outputs.cache-hit != 'true'
   run: |
     set -ex
     opam init # --disable-sandboxing