-
Notifications
You must be signed in to change notification settings - Fork 2
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
MVP: reusable workflow #1
Comments
This would be amazing. |
I would be very interested to see how this works; writing new GitHub actions is very difficult and an example would be helpful :-) |
This is how you use it: https://github.com/pkgjs/action/blob/66bf678e530a693e59a340342165238d8049e67e/.github/workflows/ci.yaml (once #2 gets merged) Gives you a matrix with lts versions, where oldest is the one from your engines. |
hm, ok - so basically you make one job in the consumer, and it can delegate the entire thing, including using a matrix, to the upstream? i'll give that a shot. |
I initially asked to create this repo so that we can try out the composite actions, but Github finally came out with reusable workflows 🎉 a few days ago, so I figure the MVP here is actually a reusable workflow.
Here's the things I think it should support for the very first draft:
upgrade-policy
ci-config-travis
:all
,lts
(default),lts-strict
engines.node
inpackage.json
; fail if undefined/invalidactions/checkout
actions/setup-node
npm install
npm test
npm test
when testing in latest version so that folks can skip linting for non-latest versionsUsage example:
I should be able to PR today (or before Monday anyways).
I'm sure there will be other features we'll want to support (e.g. passing through caching params to
setup-node
, customizingnpm
version, etc - basically anything), but I'd like to get the very basics out asap, so that we still have time to iterate on it a little bit before Node.js 16 turns LTS / Node.js 17 comes out and people start updating their workflows manually.The text was updated successfully, but these errors were encountered: