Remove snapcraft cache

This commit is contained in:
Micah Lee 2022-10-05 19:08:00 -07:00
parent e380f61ea3
commit 749466005e
No known key found for this signature in database
GPG Key ID: 403C2657CD994F73

View File

@ -315,30 +315,9 @@ jobs:
sudo lxd init --auto
sudo snap install snapcraft --classic
- name: Restore cache - snapcraft
uses: actions/cache@v3
with:
path: ~/snapcraft-cache
key: snapcraft-cache
- name: Move cache from home to root
run: |
sudo mkdir -p /root/.cache
if [[ -d "~/snapcraft-cache" ]]; then
sudo mv ~/snapcraft-cache /root/.cache/snapcraft
sudo chown -R root:root /root/.cache/snapcraft
echo "moved cache from home to root"
fi
- name: Build snap
run: sudo snapcraft --use-lxd
- name: Move cache root to home
run: |
sudo find /root
sudo mv /root/.cache/snapcraft ~/snapcraft-cache
sudo chown -R $USER:$USER ~/snapcraft-cache
- uses: actions/upload-artifact@v3
with:
name: snapcraft-build