awalsh128 / cache-apt-pkgs-action

Cache APT packages in GitHub Actions
Other
205 stars 35 forks source link

Clean cache directory after use #95

Closed pascallj closed 1 year ago

pascallj commented 1 year ago

By splitting the restore and save steps of the cache action, we can run some steps after the post cache step which otherwise would be run at the end of the workflow.

This allows us to clean the cache directory after it has been saved. This fixes #94, allows us to save the cache even if the rest of the workflow fails and also has the minor benefit of reduced disk usage.

Differences for existing workflows:

awalsh128 commented 1 year ago

Thanks again. Will fold these into a new patch in the next couple of days.

awalsh128 commented 1 year ago

Looks like there is a regression test failure I will need to look into to see if it is valid or not before patching.