Skip to content

Commit 5326de5

Browse files
committed
feat(ci): Add GitHub Actions and fix Perl 5.8 compatibility
1 parent 81980d8 commit 5326de5

File tree

1 file changed

+14
-3
lines changed

1 file changed

+14
-3
lines changed

.github/workflows/ci.yml

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
sudo apt-get install -y liblua5.3-dev
5555
elif [ "$RUNNER_OS" == "macOS" ]; then
5656
brew install lua
57-
elif [ "$RUNNER_OS" == "Windows" ];then
57+
elif [ "$RUNNER_OS" == "Windows" ]; then
5858
scoop install lua
5959
echo "LUA_LIB_PATH=C:\Users\runneradmin\scoop\apps\lua\current\lib" >> $env:GITHUB_ENV
6060
echo "LUA_INC_PATH=C:\Users\runneradmin\scoop\apps\lua\current\include" >> $env:GITHUB_ENV
@@ -64,7 +64,15 @@ jobs:
6464

6565
- name: Install Perl Dependencies
6666
run: |
67-
cpanm --notest Inline Test::Exception
67+
cpanm --notest Inline Test::Exception ExtUtils::MakeMaker
68+
69+
- name: Clean build environment
70+
run: |
71+
# Remove any cached Inline files that might cause version mismatches
72+
rm -rf _Inline blib
73+
# Clean any previous build artifacts
74+
if [ -f Makefile ]; then make clean || true; fi
75+
rm -f Makefile.old
6876
6977
- name: Build and Test
7078
run: |
@@ -74,7 +82,10 @@ jobs:
7482
perl Makefile.PL
7583
fi
7684
make
85+
# Clean Inline cache before testing to prevent version mismatch
86+
rm -rf _Inline
7787
make test TEST_VERBOSE=1
88+
shell: bash
7889

7990
- name: Run Author/Extended Tests
8091
if: matrix.perl >= 5.22 # NOTE: Author tests often use modern syntax
@@ -83,4 +94,4 @@ jobs:
8394
if [ -d "xt" ]; then
8495
cpanm --notest Test::Perl::Critic Test::Pod Test::Pod::Coverage
8596
prove -lv -r xt
86-
fi
97+
fi

0 commit comments

Comments
 (0)