-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove Travis CI config, which wasn't working anymore. The test workflow tests Perls 5.8 - 5.36 on Linux, macOS, and Windows. The release workflow uses a custom Build.PL targets to build a list of changes and to print the name of the tarball for releasing on GitHub. Requires GitHub secrets `CPAN_PASSWORD` and `CPAN_USERNAME` to release on CPAN.
- Loading branch information
Showing
5 changed files
with
100 additions
and
45 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: ✅ CI | ||
on: [push, pull_request] | ||
jobs: | ||
test: | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest, windows-latest] | ||
perl: [ '5.36', '5.34', '5.32', '5.30', '5.28', '5.26', '5.24', '5.22', '5.20', '5.18', '5.16', '5.14', '5.12', '5.10', '5.8' ] | ||
name: 🐪 Perl ${{ matrix.perl }} on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup Perl | ||
uses: shogo82148/actions-setup-perl@v1 | ||
with: | ||
perl-version: ${{ matrix.perl }} | ||
env: | ||
AUTHOR_TESTING: 1 | ||
RELEASE_TESTING: 1 | ||
- name: Build and Test | ||
# Have to build on Windows to get scripts\psql.bat. | ||
run: | | ||
perl -V | ||
cpanm --notest --installdeps . # https://github.com/Perl-Toolchain-Gang/extutils-pl2bat/issues/7 | ||
perl Build.PL | ||
perl Build code | ||
prove -lv t |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: 🚀 Release | ||
on: | ||
push: | ||
tags: [v*] | ||
jobs: | ||
release: | ||
name: 🚀 Release | ||
runs-on: ubuntu-latest | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
steps: | ||
- name: Check out the repo | ||
uses: actions/checkout@v3 | ||
- name: Setup Perl | ||
uses: shogo82148/actions-setup-perl@v1 | ||
- name: Install Release Dependencies | ||
run: cpanm -qn Module::Build CPAN::Uploader | ||
|
||
# CPAN | ||
- name: Package the Release | ||
id: package | ||
run: perl Build.PL && ./Build manifest && ./Build dist && echo "tarball=$(./Build tarball_name)" >> $GITHUB_OUTPUT | ||
- name: Generate Release Changes | ||
run: ./Build latest_changes | ||
- name: Release on CPAN | ||
env: | ||
CPANPASS: ${{ secrets.CPAN_PASSWORD }} | ||
CPANUSER: ${{ secrets.CPAN_USERNAME }} | ||
run: cpan-upload --user "$CPANUSER" --password "$CPANPASS" '${{ steps.package.outputs.tarball }}' | ||
|
||
# GitHub | ||
- name: Create GitHub Release | ||
id: release | ||
uses: actions/create-release@v1 | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: Release ${{ github.ref }} | ||
body_path: latest_changes.md | ||
- name: Upload Release Asset | ||
uses: actions/upload-release-asset@v1 | ||
with: | ||
upload_url: ${{ steps.release.outputs.upload_url }} | ||
asset_path: ./${{ steps.package.outputs.tarball }} | ||
asset_name: ${{ steps.package.outputs.tarball }} | ||
asset_content_type: application/gzip |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,3 +7,4 @@ | |
/Build | ||
/Makefile* | ||
/pm_to_blib | ||
/latest_changes.md |
This file was deleted.
Oops, something went wrong.
This file contains 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