Store LICENSE files when publishing from GH actions#12810
Store LICENSE files when publishing from GH actions#12810nicolo-ribaudo merged 2 commits intobabel:mainfrom
Conversation
nicolo-ribaudo
commented
Feb 16, 2021
| Q | A |
|---|---|
| Fixed Issues? | Fixes #12807 |
| Patch: Bug Fix? | |
| Major: Breaking Change? | |
| Minor: New Feature? | |
| Tests Added + Pass? | Yes |
| Documentation PR Link | |
| Any Dependency Changes? | |
| License | MIT |
|
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/40709/ |
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 47e6e1d:
|
| name: build-artifact | ||
|
|
||
| - name: Generate LICENSE files | ||
| run: make clone-license |
There was a problem hiding this comment.
So it wasn't being added in make prepublish? or removed?
There was a problem hiding this comment.
The problem was that we are running make prepublish in a different job, and to reduce CI times we only store these files:
babel/.github/workflows/release.yml
Lines 45 to 49 in 8e9143f
There was a problem hiding this comment.
We can add the cloned license to build artifacts then. It won't affect development build since they are not generated.
Or we can merge the build job to the release job instead. The artifacts are meant to speed up CI in node matrix scenarios.
There was a problem hiding this comment.
The reason I split the jobs is because the "Publish release on npm" job has access to our npm token, so I wanted to run as few things as possible in it.
Currently it's only running yarn release-tool publish --yes, which means that it only runs code bundled ahead of time in this repository.
I prefer to add LICENSE files to the artifact.
|
I can release a patch tomorrow. It needs to be done locally because we need need to force-publish all the packages that we published without a license. |