Re: [PATCH] CI: Add a CPAN cache on Windows

From: Jacob Champion <jacob(dot)champion(at)enterprisedb(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Nazir Bilal Yavuz <byavuz81(at)gmail(dot)com>
Subject: Re: [PATCH] CI: Add a CPAN cache on Windows
Date: 2026-06-05 19:27:50
Message-ID: CAOYmi+mxT6R7yqe=f34T0EQLA_ho1tLUzXgKQbUTazMP2zULng@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jun 5, 2026 at 11:38 AM Andres Freund <andres(at)anarazel(dot)de> wrote:
> In 93d97349461347d952e8cebdf62f5aa84b4bd20a, I kinda had implemented such
> caching for macos. There I used
> PERL5LIB: ${HOME}/perl5/lib/perl5
>
> to put the cache somewhere under our control. Any reason to not do that?

As a Perl novice, I was worried about setting that. The Windows
runners have multiple installations of Perl and I don't want them to
ever collide (similar to my PYTHONHOME concern in the other thread).
Is that a reasonable fear?

> > - - name: Install dependencies
> > + # Rebuild the CPAN cache whenever `perl -V` changes.
> > + - name: Compute Perl version cache key
> > + id: perlkey
> > + shell: 'C:\msys64\usr\bin\bash.exe --login -eo pipefail "{0}"'
> > + run: |
> > + perl_hash=$(/c/Strawberry/perl/bin/perl -V | md5sum | cut -f1 -d ' ')
> > + echo "key=perl${perl_hash}" >> "$GITHUB_OUTPUT"
>
> Hm. It'd be nicer if we didn't have to repeat this part between the two
> tasks... Perhaps we can make it work using the small overlap between the
> different shells?
>
> Or maybe shell: bash would actually work well enough between the tasks (without
> -- login it might not overwrite PATH).

I'll see if I can make something work.

Thanks!
--Jacob

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ayush Tiwari 2026-06-05 19:27:56 Remove the refint contrib module (for v20)
Previous Message Daniel Gustafsson 2026-06-05 19:25:27 Re: oauth integer overflow