-
Notifications
You must be signed in to change notification settings - Fork 519
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
build: add snapshot build support #1547
Conversation
@alexeagle I'll add the source trees to the commit so we get the diffs. I think the next step here is to ask bazelbuild for a new repo named |
70f3d5b
to
e186d34
Compare
Added the release artifacts sources: https://github.com/gregmagolan/rules_nodejs-builds/tree/labs And docs show up too for each npm packages with the README.md: https://github.com/gregmagolan/rules_nodejs-builds/tree/labs/%40bazel_typescript |
Oh would you look at that. @bazel/typescript includes in external npm deps. Whoops: https://unpkg.com/browse/@bazel/typescript@1.1.0/external/npm/node_modules/ Should fix that. Made an issue so we don't forget: #1551 |
343e28e
to
8cc1ffd
Compare
8cc1ffd
to
7ba5fbc
Compare
b406166
to
e1892fe
Compare
e1892fe
to
82576fd
Compare
82576fd
to
a0df20c
Compare
This Pull Request has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs in two weeks. Collaborators can add a "cleanup" or "need: discussion" label to keep it open indefinitely. Thanks for your contributions to rules_nodejs! |
This PR was automatically closed because it went two weeks without a reply since it was labeled "Can Close?" |
Example of a generated and published snapshot build at https://github.com/gregmagolan/rules_nodejs-builds/tree/labs.
The first argument of the script is the GitHub org to publish to. In the above case it is my GitHub account
gregmagolan
. Ideally, we'd publish snapshot builds from CI to https://github.com/bazelbuild/rules_nodejs-builds but some discussion as to if this is the best solution is needed first and we need to ask bazelbuild for another reporules_nodejs-builds
.A few points from offline discussion:
publishing each npm package to its own repo as angular does (https://github.com/angular/core-builds, https://github.com/angular/http-builds, etc...) is not a great solution since we would be publishing to the bazelbuild org and we would both spam their repositories list and need to ask for a new repository for every new npm package
the last point is why I chose to publish .tar.gz files to this one repo for all of the npm packages. This works well for fetching these in your package.json with:
"@bazel/terser": "https://github.com/gregmagolan/rules_nodejs-builds/raw/1.1.0+7e1ec700/@bazel_terser-labs-snapshot.tar.gz"
publishing snapshots to npm is not desirable as it would span the npm versions and we want to reserve
next
for rcspublishing to the main repo https://github.com/bazelbuild/rules_nodejs is not desirable as it would make that repository grow in size by adding binary files to it and if you pull all branches on clone you would have to download all of the snapshot releases
one benefit of the angular approach is that it makes it easy to see diffs in the release artifacts with each commit which we don't get here with the .tar.gz. It would be fairly easy to add the contents of the .tar.gz along side the binary archive in the commit so that diffs in the release artifacts would be available under a single repo (best of both worlds)
considered making releases for each snapshot built to https://github.com/bazelbuild/rules_nodejs-builds using the GitHub API to upload release artifacts but that would not be as easy to navigate between branches and snapshots between branches would be interleaved in the release logs. You would also not get release artifacts diffs from the last point.