[latex3-commits] [git/LaTeX3-latex3-latex2e] workflow_update: Simplify caching in GH Actions workflows (01e9ff89)

Marcel Fabian Krüger tex at 2krueger.de
Tue Nov 29 00:07:40 CET 2022


Repository : https://github.com/latex3/latex2e
On branch  : workflow_update
Link       : https://github.com/latex3/latex2e/commit/01e9ff898752cf892273e08b2d52dece1a29517b

>---------------------------------------------------------------

commit 01e9ff898752cf892273e08b2d52dece1a29517b
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date:   Tue Nov 29 00:07:40 2022 +0100

    Simplify caching in GH Actions workflows


>---------------------------------------------------------------

01e9ff898752cf892273e08b2d52dece1a29517b
 .github/workflows/cache.yaml  | 21 +--------------------
 .github/workflows/deploy.yaml | 21 +--------------------
 .github/workflows/main.yaml   | 21 +--------------------
 3 files changed, 3 insertions(+), 60 deletions(-)

diff --git a/.github/workflows/cache.yaml b/.github/workflows/cache.yaml
index 6e2f6a7d..ca3b99ee 100644
--- a/.github/workflows/cache.yaml
+++ b/.github/workflows/cache.yaml
@@ -17,27 +17,8 @@ jobs:
     runs-on: ubuntu-20.04
     name: Update TeX Live
     steps:
-      # GitHub Actions don't regenerate the test if the key doesn't change, so
-      # we integrate a random UUID into the key to keep them different.
-      # DO NOT CHANGE THIS
-      - name: Generate unique ID
-        id: get-id
-        run: |
-          echo "id=$(cat /proc/sys/kernel/random/uuid)" >> $GITHUB_OUTPUT
-      # Actually load the cache. Since we never reuse the key, we need restore-keys
-      # to indicate the prefix of our caches. This loads the newest cache with this
-      # prefix in the key.
-      #
-      # If we want to force regeneration of the cache, increase the number after
-      # *both* instances of "texlive-v" and synchronize the other workflow files.
-      - name: Load cache
-        uses: actions/cache at v3
-        with:
-          path: ~/texlive
-          key: texlive2022-v0-${{ steps.get-id.outputs.id }}
-          restore-keys: texlive2022-v0-
       - name: Install TeX Live
-        uses: zauguin/install-texlive at v1
+        uses: zauguin/install-texlive at v2
         with:
           # List the required TeX Live packages in a separate file to allow reuse in
           # different workflows.
diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml
index 26b8cd97..4f37994f 100644
--- a/.github/workflows/deploy.yaml
+++ b/.github/workflows/deploy.yaml
@@ -17,25 +17,6 @@ jobs:
       # Boilerplate
       - name: Checkout repository
         uses: actions/checkout at v3
-      # GitHub Actions don't regenerate the test if the key doesn't change, so
-      # we integrate a random UUID into the key to keep them different.
-      # DO NOT CHANGE THIS
-      - name: Generate unique ID
-        id: get-id
-        run: |
-          echo "id=$(cat /proc/sys/kernel/random/uuid)" >> $GITHUB_OUTPUT
-      # Actually load the cache. Since we never reuse the key, we need restore-keys
-      # to indicate the prefix of our caches. This loads the newest cache with this
-      # prefix in the key.
-      #
-      # If we want to force regeneration of the cache, increase the number after
-      # *both* instances of "texlive-v"
-      - name: Load cache
-        uses: actions/cache at v3
-        with:
-          path: ~/texlive
-          key: texlive2022-v0-${{ steps.get-id.outputs.id }}
-          restore-keys: texlive2022-v0-
       # We need Ghostscript for dvips and XeTeX tests.
       - run: sudo apt-get update && sudo apt-get install ghostscript
       # Determine the name of the tag we are working on. Sadly GH Actions only provides
@@ -50,7 +31,7 @@ jobs:
           string: ${{ github.ref }}
           replace-with: ""
       - name: Install TeX Live
-        uses: zauguin/install-texlive at v1
+        uses: zauguin/install-texlive at v2
         with:
           # List the required TeX Live packages in a separate file to allow reuse in
           # different workflows.
diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml
index 5eef598d..3a01ab02 100644
--- a/.github/workflows/main.yaml
+++ b/.github/workflows/main.yaml
@@ -43,29 +43,10 @@ jobs:
       # Boilerplate
       - name: Checkout repository
         uses: actions/checkout at v3
-      # GitHub Actions don't regenerate the test if the key doesn't change, so
-      # we integrate a random UUID into the key to keep them different.
-      # DO NOT CHANGE THIS
-      - name: Generate unique ID
-        id: get-id
-        run: |
-          echo "id=$(cat /proc/sys/kernel/random/uuid)" >> $GITHUB_OUTPUT
-      # Actually load the cache. Since we never reuse the key, we need restore-keys
-      # to indicate the prefix of our caches. This loads the newest cache with this
-      # prefix in the key.
-      #
-      # If we want to force regeneration of the cache, increase the number after
-      # *both* instances of "texlive-v"
-      - name: Load cache
-        uses: actions/cache at v3
-        with:
-          path: ~/texlive
-          key: texlive2022-v0-${{ steps.get-id.outputs.id }}
-          restore-keys: texlive2022-v0-
       # We need Ghostscript for dvips and XeTeX tests.
       - run: sudo apt-get update && sudo apt-get install ghostscript
       - name: Install TeX Live
-        uses: zauguin/install-texlive at v1
+        uses: zauguin/install-texlive at v2
         with:
           # List the required TeX Live packages in a separate file to allow reuse in
           # different workflows.





More information about the latex3-commits mailing list.