From 3c82d49849b7dc521157444f58cdc09c77d5b165 Mon Sep 17 00:00:00 2001 From: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> Date: Fri, 20 Mar 2026 17:53:09 +1100 Subject: [PATCH] ci: cache aur packages --- .github/actions/setup-arch/action.yml | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/.github/actions/setup-arch/action.yml b/.github/actions/setup-arch/action.yml index 5f419297..5f0e3dfc 100644 --- a/.github/actions/setup-arch/action.yml +++ b/.github/actions/setup-arch/action.yml @@ -12,7 +12,9 @@ runs: - name: Restore package cache uses: actions/cache/restore@v4 with: - path: /var/cache/pacman/pkg + path: | + /var/cache/pacman/pkg + /home/builder/.cache/yay key: pacman-${{ steps.date.outputs.week }}-${{ hashFiles('.github/actions/setup-arch/action.yml') }} restore-keys: | pacman-${{ steps.date.outputs.week }}- @@ -23,23 +25,24 @@ runs: run: | pacman -Syu --needed --noconfirm sudo base-devel cmake ninja fish git clang qt6-declarative python - - name: Install quickshell-git + - name: Install yay shell: bash run: | useradd -m builder echo 'builder ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers - install_pkg() { - sudo -u builder git clone https://aur.archlinux.org/$1.git /home/builder/$1 - cd /home/builder/$1 - sudo -u builder makepkg -si --noconfirm - } + sudo -u builder git clone https://aur.archlinux.org/yay-bin.git /home/builder/yay-bin + cd /home/builder/yay-bin + sudo -u builder makepkg -si --noconfirm - install_pkg cpptrace # Dep for qs - install_pkg quickshell-git + - name: Install quickshell-git + shell: bash + run: sudo -u builder yay -S --noconfirm quickshell-git - name: Save packages to cache uses: actions/cache/save@v4 with: - path: /var/cache/pacman/pkg + path: | + /var/cache/pacman/pkg + /home/builder/.cache/yay key: pacman-${{ steps.date.outputs.week }}-${{ hashFiles('.github/actions/setup-arch/action.yml') }}