Skip to content

add windows to ci #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 71 additions & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: windows

on:
push:
branches:
- '*'
tags-ignore:
- '*'
pull_request:

env:
PERL5LIB: c:\cx\lib\perl5
PERL_LOCAL_LIB_ROOT: c:/cx
PERL_MB_OPT: --install_base C:/cx
PERL_MM_OPT: INSTALL_BASE=C:/cx

jobs:
perl:

runs-on: windows-latest

strategy:
fail-fast: false
matrix:
alien:
- install_type: share
- install_type: system

env:
ALIEN_INSTALL_TYPE: ${{ matrix.alien.install_type }}

steps:
- uses: actions/checkout@v2

- name: Set up Perl
run: |
choco install strawberryperl
echo "C:\cx\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
echo "C:\strawberry\c\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
echo "C:\strawberry\perl\site\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
echo "C:\strawberry\perl\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append

- name: perl -V
run: |
perl -V

- name: Prepare for cache
run: |
perl -V > perlversion.txt
dir perlversion.txt

- name: Cache CPAN modules
uses: actions/cache@v1
with:
path: c:\cx
key: ${{ runner.os }}-build-${{ matrix.alien.install_type }}-${{ hashFiles('perlversion.txt') }}
restore-keys: |
${{ runner.os }}-build-${{ matrix.alien.install_type }}-${{ hashFiles('perlversion.txt') }}

- name: Install Static Dependencies
run: |
cpanm -n Dist::Zilla
dzil authordeps --missing | env ALIEN_INSTALL_TYPE=default cpanm -n
dzil listdeps --missing | env ALIEN_INSTALL_TYPE=default cpanm -n

- name: Install Dynamic Dependencies
run: |
dzil run --no-build 'cpanm --installdeps .'

- name: Run Tests
run: dzil test -v
2 changes: 2 additions & 0 deletions dist.ini
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ installer = Author::Plicease::MakeMaker
test2_v0 = 1
github_user = PerlAlien
irc = irc://irc.perl.org/#native

workflow = windows
workflow = linux

[AlienBuild]
Expand Down