From 0dd5ec7dfefb70428f1904154fab972c060d9baf Mon Sep 17 00:00:00 2001 From: Butterscotch! Date: Mon, 16 Jan 2023 09:22:52 -0500 Subject: [PATCH] Use `cache-apt-pkgs-action` for apt instead (#474) --- .github/workflows/build-gui.yml | 12 +++++++++--- .github/workflows/gradle.yaml | 12 +++++++++--- 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-gui.yml b/.github/workflows/build-gui.yml index 312094a84..9dd5912a9 100644 --- a/.github/workflows/build-gui.yml +++ b/.github/workflows/build-gui.yml @@ -36,9 +36,15 @@ jobs: - if: matrix.os == 'ubuntu-20.04' name: Set up Linux dependencies - run: | - sudo apt-get update - sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf + uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf + # Increment to invalidate the cache + version: 1.0 + # Enables a workaround to attempt to run pre and post install scripts + execute_install_scripts: true + # Disables uploading logs as a build artifact + debug: false - name: Cache cargo dependencies uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/gradle.yaml b/.github/workflows/gradle.yaml index 85bc2dac7..6174ba5b2 100644 --- a/.github/workflows/gradle.yaml +++ b/.github/workflows/gradle.yaml @@ -80,9 +80,15 @@ jobs: path: server/build/libs/ - name: Set up Linux dependencies - run: | - sudo apt-get update - sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf libfuse2 + uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf libfuse2 + # Increment to invalidate the cache + version: 1.0 + # Enables a workaround to attempt to run pre and post install scripts + execute_install_scripts: true + # Disables uploading logs as a build artifact + debug: false - name: Cache cargo dependencies uses: Swatinem/rust-cache@v2