From 8977940719c27dbcbf5114f5288e1bca357e54bc Mon Sep 17 00:00:00 2001 From: Ferenc Erki Date: Mon, 18 Apr 2022 00:42:50 +0200 Subject: [PATCH] Cache build dependencies --- .github/workflows/build_and_test.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 61b4611..8dc2764 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -22,9 +22,16 @@ jobs: - name: Setup Perl id: perl uses: shogo82148/actions-setup-perl@v1 + - name: Get build timestamp + run: echo BUILD_TIMESTAMP="$(date +%FT%T)" >> $GITHUB_ENV + - name: Cache build dependencies + uses: actions/cache@v3 with: - install-modules-with: cpm - install-modules: Dist::Zilla + path: local + key: cache-build-deps-${{ steps.perl.outputs.perl-hash }}-${{ env.BUILD_TIMESTAMP }} + restore-keys: cache-build-deps-${{ steps.perl.outputs.perl-hash }}- + - name: Install Dist::Zilla + run: cpm install Dist::Zilla - name: Install author dependencies run: dzil authordeps | cpm install --show-build-log-on-failure - - name: Build dist