Skip to content

Commit 2a74fe8

Browse files
committed
Advertise perl-versions in documentation
1 parent 10d60f0 commit 2a74fe8

File tree

1 file changed

+21
-13
lines changed

1 file changed

+21
-13
lines changed

README.md

+21-13
Original file line numberDiff line numberDiff line change
@@ -28,29 +28,37 @@ This action installs 'cpanminus' then use it if needed to install some Perl Modu
2828

2929
## Using install-with-cpanm in a GitHub workflow
3030

31-
Here is a sample integration using install-with-cpanm action
31+
Here is a sample integration using `install-with-cpanm` action
3232
to test your Perl Modules using multiple Perl versions via the
33-
perl-tester images.
33+
`perl-tester` images and the action `perl-actions/perl-versions` to rely on a dynamic list of available Perl versions.
3434

3535
```yaml
36-
# .github/workflows/linux.yml
36+
# .github/workflows/testsuite.yml
3737
jobs:
38+
39+
perl-versions:
40+
runs-on: ubuntu-latest
41+
name: List Perl versions
42+
outputs:
43+
perl-versions: ${{ steps.action.outputs.perl-versions }}
44+
steps:
45+
- id: action
46+
uses: perl-actions/perl-versions@v1
47+
with:
48+
since-perl: v5.10
49+
with-devel: true
50+
3851
perl_tester:
3952
runs-on: ubuntu-latest
40-
name: "perl v${{ matrix.perl-version }}"
53+
name: "Perl ${{ matrix.perl-version }}"
54+
needs: [perl-versions]
4155

4256
strategy:
4357
fail-fast: false
4458
matrix:
45-
perl-version:
46-
- "5.30"
47-
- "5.28"
48-
- "5.26"
49-
# ...
50-
# - '5.8'
51-
52-
container:
53-
image: perldocker/perl-tester:${{ matrix.perl-version }}
59+
perl-version: ${{ fromJson (needs.perl-versions.outputs.perl-versions) }}
60+
61+
container: perldocker/perl-tester:${{ matrix.perl-version }}
5462

5563
steps:
5664
- uses: actions/checkout@v4

0 commit comments

Comments
 (0)