Skip to content

Commit a7c724e

Browse files
committed
build: Also add required perl libraries cache support for windows build
1 parent 4094c36 commit a7c724e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

.github/workflows/glpi-agent-packaging.yml

+11
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,15 @@ jobs:
214214
dir C:\Strawberry-perl-for-GLPI-Agent_build\download
215215
dir C:\Strawberry-perl-for-GLPI-Agent_build\restore
216216
shell: cmd
217+
- name: Restore required perl libraries cache
218+
uses: actions/cache@v4
219+
id: perl-site-cache
220+
if: steps.built-perl-cache.outputs.cache-hit == 'true'
221+
with:
222+
path: |
223+
C:\Strawberry\perl\site\lib
224+
C:\Strawberry\perl\site\bin
225+
key: built-perl-windows-packaging-perl-site-cache-${{ matrix.arch }}-${{ hashFiles('contrib\windows\glpi-agent-extlibs-build.pl', 'contrib\windows\glpi-agent-packaging.pl', 'contrib\windows\packaging\*') }}
217226
- name: Update environment
218227
run: |
219228
echo 'C:\Strawberry\perl\bin' >> $GITHUB_PATH
@@ -227,12 +236,14 @@ jobs:
227236
perl -V
228237
shell: cmd
229238
- name: Install Module::Install
239+
if: steps.perl-site-cache.outputs.cache-hit != 'true'
230240
run: cpan -T Module::Install
231241
shell: cmd
232242
- name: Prepare Makefile
233243
run: perl Makefile.PL
234244
shell: cmd
235245
- name: Install latest Perl::Dist::Strawberry from github
246+
if: steps.perl-site-cache.outputs.cache-hit != 'true'
236247
run: |
237248
cpanm --notest --verbose https://github.com/StrawberryPerl/Perl-Dist-Strawberry.git
238249
shell: cmd

0 commit comments

Comments
 (0)