ci: cache chocolaty download
authorRan Benita <ran@unusedvar.com>
Wed, 22 Jul 2020 09:02:44 +0000 (12:02 +0300)
committerRan Benita <ran@unusedvar.com>
Wed, 22 Jul 2020 10:45:17 +0000 (13:45 +0300)
The bison sourceforge download is quite slow and unreliable.

Hopefully this works. Stolen directly from ruby:
https://github.com/ruby/ruby/blob/a50750c8a960ef62b3e1dbd78b12056f0512b17d/.github/workflows/windows.yml#L26

Signed-off-by: Ran Benita <ran@unusedvar.com>
.github/workflows/main.yml

index 4f51763..5c56dbb 100644 (file)
@@ -68,6 +68,13 @@ jobs:
       - uses: actions/setup-python@v1
         with:
           python-version: '3.7'
+      - uses: actions/cache@v2
+        with:
+          path: C:\Users\runneradmin\AppData\Local\Temp\chocolatey
+          key: ${{ runner.os }}-chocolatey-${{ matrix.os }}-${{ github.sha }}
+          restore-keys: |
+            ${{ runner.os }}-chocolatey-${{ matrix.os }}-
+            ${{ runner.os }}-chocolatey-
       - name: Install dependencies
         run: |
           python -m pip install --upgrade pip meson