- uses: actions/cache@v2
id: cache-packages # give it a name for checking the cache hit-or-not
with:
path: ./packages/ # what we cache: the folder
key: $\{\{ runner.os }}-packages-$\{\{ hashFiles('**/packages*.txt') }}
restore-keys: |
$\{\{ runner.os }}-packages-
- run: package-installer packages.txt
if: steps.cache-packages.outputs.cache-hit != 'true'