Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: migrate to GitHub Actions w/ matrix #84

Merged
merged 2 commits into from
Jun 11, 2022
Merged

Conversation

agilgur5
Copy link
Owner

Summary

Migrate from Travis CI to GitHub Actions plus add a testing matrix

Details

- Travis CI is only _pseudo_-free after the .org -> .com merge
  - c.f. https://travis-ci.community/t/org-com-migration-unexpectedly-comes-with-a-plan-change-for-oss-what-exactly-is-the-new-deal/10567
  - and honestly, has glitches occasionally where my builds don't run or I can't manually re-run either

- GH Actions are _actually_ free for OSS / public repos
  - and also offer a decent level of composability that's resulted in a huge surge in reusable community Actions (vs. CircleCI orbs etc haven't had nearly as much adoption)
  - and I've had a mostly great experience on them so far as well

- also add a matrix for all Node LTS and all OSes
- and upgrade to the Codecov GH Action, since the bash uploader was deprecated (https://about.codecov.io/blog/introducing-codecovs-new-uploader/)

- this is basically a mix of the Actions I helped set-up in rpt2's repo and the TSDX templates:
  - https://github.com/ezolenko/rollup-plugin-typescript2/blob/03cfb048adcf39de56bd4566dc9a7300534a3cc1/.github/workflows/nodejs.yml
  - https://github.com/jaredpalmer/tsdx/blob/2d7981b00b2bf7363a3eeff44ff5ff698ba58c8c/templates/basic/.github/workflows/main.yml
  - plus upgrades to all the Actions, for instance, newer `setup-node` now has caching built-in
@agilgur5 agilgur5 added the kind: internal Changes only affect the internals and not the API or usage label Jun 11, 2022
@agilgur5
Copy link
Owner Author

Welp, Node 18 is having some issues installing node-canvas, seems to be an upstream issue: Automattic/node-canvas#2025

Will remove Node 18 from the matrix for now then

- per the in-line comment, there are some upstream issues in node-canvas that is causing installation to fail on Node 18
- made a TODO to add Node 18 back to the matrix once it's properly supported upstream
@codecov
Copy link

codecov bot commented Jun 11, 2022

Codecov Report

Merging #84 (6888bf2) into main (3db849f) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##              main       #84   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines           75        75           
  Branches         9         9           
=========================================
  Hits            75        75           

Continue to review full report at Codecov.

Legend - Click here to learn more
螖 = absolute <relative> (impact), 酶 = not affected, ? = missing data
Powered by Codecov. Last update 3db849f...6888bf2. Read the comment docs.

@agilgur5
Copy link
Owner Author

Changed the required checks for the main branch to use one of the GH Actions checks instead of the Travis CI check

Copy link
Owner Author

@agilgur5 agilgur5 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM and CI matrix passes 馃檪 馃帀

@agilgur5 agilgur5 merged commit 514dec0 into main Jun 11, 2022
@agilgur5 agilgur5 deleted the ci-migrate-github-actions branch June 11, 2022 02:38
@agilgur5 agilgur5 added the scope: tests Tests could be improved. Or changes that only affect tests label Jun 11, 2022
agilgur5 added a commit that referenced this pull request Jun 16, 2022
backport of 514dec0
- plus some `package.json#scripts`
- and remove the typechecking from the CI workflow since the v1.0.x line is pre-TS

* ci: migrate to GitHub Actions w/ matrix

- Travis CI is only _pseudo_-free after the .org -> .com merge
  - c.f. https://travis-ci.community/t/org-com-migration-unexpectedly-comes-with-a-plan-change-for-oss-what-exactly-is-the-new-deal/10567
  - and honestly, has glitches occasionally where my builds don't run or I can't manually re-run either

- GH Actions are _actually_ free for OSS / public repos
  - and also offer a decent level of composability that's resulted in a huge surge in reusable community Actions (vs. CircleCI orbs etc haven't had nearly as much adoption)
  - and I've had a mostly great experience on them so far as well

- also add a matrix for all Node LTS and all OSes
- and upgrade to the Codecov GH Action, since the bash uploader was deprecated (https://about.codecov.io/blog/introducing-codecovs-new-uploader/)

- this is basically a mix of the Actions I helped set-up in rpt2's repo and the TSDX templates:
  - https://github.com/ezolenko/rollup-plugin-typescript2/blob/03cfb048adcf39de56bd4566dc9a7300534a3cc1/.github/workflows/nodejs.yml
  - https://github.com/jaredpalmer/tsdx/blob/2d7981b00b2bf7363a3eeff44ff5ff698ba58c8c/templates/basic/.github/workflows/main.yml
  - plus upgrades to all the Actions, for instance, newer `setup-node` now has caching built-in

* fix(ci): remove Node 18 due to node-canvas installation issues

- per the in-line comment, there are some upstream issues in node-canvas that is causing installation to fail on Node 18
- made a TODO to add Node 18 back to the matrix once it's properly supported upstream

* env: reorganize `package.json#scripts`

- need `test:coverage` for the CI workflow
- add other scripts from `main` branch
- and reorder scripts to be the same as `main` as well
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind: internal Changes only affect the internals and not the API or usage scope: tests Tests could be improved. Or changes that only affect tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant