This repository was archived by the owner on Oct 10, 2025. It is now read-only.
ci: fix GitHub Actions workflow to use only trusted actions #2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Testing | |
on: | |
push: | |
branches: [main, develop] | |
pull_request: | |
branches: [main, develop] | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
name: Lint | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo npm install -g markdownlint-cli | |
- name: Run linting | |
run: markdownlint "**/*.md" | |
test: | |
runs-on: ubuntu-latest | |
name: Test | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install Perl and dependencies | |
run: | | |
# Ubuntu already has Perl 5.34+ installed | |
perl -v | |
# Install cpanminus | |
curl -L https://cpanmin.us | perl - App::cpanminus | |
# Setup local::lib | |
cpanm --local-lib=~/perl5 local::lib | |
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib) | |
# Install Carmel | |
cpanm Carmel | |
# Add to PATH for subsequent steps | |
echo "$HOME/perl5/bin" >> $GITHUB_PATH | |
- name: Install project dependencies | |
run: | | |
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib) | |
carmel install | |
- name: Run tests | |
run: | | |
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib) | |
carmel exec -- prove -l t/ |