emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/bnf-mode b8f1a23fd9 04/15: Use cache for Cask and depen


From: ELPA Syncer
Subject: [elpa] externals/bnf-mode b8f1a23fd9 04/15: Use cache for Cask and dependencies during the CI/CD phases
Date: Wed, 7 Dec 2022 19:57:23 -0500 (EST)

branch: externals/bnf-mode
commit b8f1a23fd9438204fd8505faa9596efeccdf97e6
Author: Serghei Iakovlev <egrep@protonmail.ch>
Commit: Serghei Iakovlev <egrep@protonmail.ch>

    Use cache for Cask and dependencies during the CI/CD phases
---
 .github/workflows/build.yml   | 20 +++++++++++++++++---
 .github/workflows/release.yml | 25 +++++++++++++++++++++----
 2 files changed, 38 insertions(+), 7 deletions(-)

diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index e64024cc80..856dd9406d 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -62,13 +62,27 @@ jobs:
         with:
           version: ${{ matrix.emacs_version }}
 
+      - uses: actions/cache@v3
+        id: cache-cask-packages
+        with:
+          path: .cask
+          key: cask-packages-${{ matrix.emacs_version }}-${{ 
hashFiles('**/Cask') }}
+
+      - uses: actions/cache@v3
+        id: cache-cask-executable
+        with:
+          path: ~/.cask
+          key: cask-executable-${{ matrix.emacs_version }}
+
       - name: Setup Cask
-        run: git clone https://github.com/cask/cask ~/.cask
+        uses: cask/setup-cask@master
+        if: steps.cache-cask-executable.outputs.cache-hit != 'true'
+        with:
+          version: snapshot
 
       - name: Set Environment Variables
         run: |
           echo "$HOME/.cask/bin" >> $GITHUB_PATH
-
           if [ "${{ matrix.emacs_version }}" != "snapshot" ]; then
             echo UNDERCOVER_FORCE=1 >> $GITHUB_ENV
           fi
@@ -77,13 +91,13 @@ jobs:
         run: make help
 
       - name: Initialize the Project
+        if: steps.cache-cask-packages.outputs.cache-hit != 'true'
         run: make init
 
       - name: Byte Compile BNF Mode
         run: make build
 
       - name: Check for Errors in the Documentation
-        if: matrix.emacs_version >= '25.1'
         run: make checkdoc
 
       - name: Run Unit Tests
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index c4d2f7aff8..e098e871d3 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -29,7 +29,7 @@ jobs:
 
     steps:
       - name: Checkout Code
-        uses: actions/checkout@v2-beta
+        uses: actions/checkout@v3
         with:
           fetch-depth: 1
 
@@ -38,13 +38,29 @@ jobs:
         with:
           version: 28.2
 
+      - uses: actions/cache@v3
+        id: cache-cask-packages
+        with:
+          path: .cask
+          key: cask-packages-${{ matrix.emacs_version }}-${{ 
hashFiles('**/Cask') }}
+
+      - uses: actions/cache@v3
+        id: cache-cask-executable
+        with:
+          path: ~/.cask
+          key: cask-executable-${{ matrix.emacs_version }}
+
       - name: Setup Cask
-        run: git clone https://github.com/cask/cask ~/.cask
+        uses: cask/setup-cask@master
+        if: steps.cache-cask-executable.outputs.cache-hit != 'true'
+        with:
+          version: snapshot
 
       - name: Set Environment Variables
         run: |
           echo "$HOME/.cask/bin" >> $GITHUB_PATH
           echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
+          echo DEBIAN_FRONTEND=noninteractive >> $GITHUB_ENV
 
       - name: Common settings
         run: |
@@ -67,6 +83,7 @@ jobs:
           sudo dpkg -i pandoc-2.7.2-1-amd64.deb
 
       - name: Initialize the Project
+        if: steps.cache-cask-packages.outputs.cache-hit != 'true'
         run: make init
 
       - name: Build Package
@@ -79,7 +96,7 @@ jobs:
 
       - name: Create Release
         id: create_release
-        uses: actions/create-release@v1.0.0
+        uses: actions/create-release@v1
         env:
           GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
         with:
@@ -90,7 +107,7 @@ jobs:
 
       - name: Upload Release Asset
         id: upload-release-asset
-        uses: actions/upload-release-asset@v1.0.1
+        uses: actions/upload-release-asset@v1
         env:
           GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
         with:



reply via email to

[Prev in Thread] Current Thread [Next in Thread]