-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat: Automatically publish artifacts to GitHub #18
Conversation
Travis docs for GitHub releases uploading contains more details on configuration options. |
TODO: Test this on one of my own repos by creating a tag and having Travis build and upload the release. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @seanprashad really exited to get this pipeline integrated into the project!
You mention that you'd be looking for me to generate the API token to enable this integration; how should we combine your work with that piece of data you need from me?
Really happy to see the sha1sum
calculation, verifying download integrity is useful especially since we're moving these files between a few different systems.
How does provider: releases
interact with the build matrix we've already got implemented? We're building on linux/windows x stable/beta/nightly (6 separate build results), how does it differentiate the build environment configurations and make sure the files are all uniquely named?
Ideally I'd like to see something like supernova-{major.minor.patch}-{platform}-{arch}
on the Releases page, possibly as a compressed/archived file that contains the compiled artifact, the license(s) and maybe some documentation/README. I'm looking at https://github.com/rustwasm/wasm-pack/releases for inspiration on how we could organize the artifacts.
I haven't forgotten about this - just have my ✋ ✋ tied with other coursework right now |
No worries! Thanks for the update. |
Hey @seanprashad, just wanted to check in and see how this pull request is going. |
We were discussing the encrypted API token to enable direct upload of build artifacts to GitHub, and I think we might be better served by defining this kind of credential in the repository settings, especially because it's a value that should probably not be automatically available to forks as only the upstream @seanprashad let me know what you think the best direction would be, and a name for the env var, I can get it added to the repository settings a lot more quickly than creating & encrypting it before sending to you and it should be available immediately on this pull request so you can test it out. |
Sweet - I think the repo setting will be just as good. Can we use GH_TOKEN: &GH_TOKEN
script:
secure: with this: api_key: `GH_TOKEN` I'll also beef up the conditional settings for when we are going to deploy by adding
|
@0xazure I know testing this patch will be quite tricky which is why I've added you to my fork that is setup with Travis. I would recommend testing out the following four scenarios:
Just make sure to leave this branch, |
Done, I've added it to the Travis env variables for Agreed with the four scenarios, artifacts should only be uploaded for tagged releases on |
Should note that tags don't need to be made on This means that we can tag any branch, push to GitHub and it'll upload artifacts to GitHub Releases. See an example here for |
Travis will now publish a tarball containing the README, LICENSE-MIT, LICENSE-APACHE and the executable for Supernova. This process is done only for the Linux and Windows stable builds upon pushing a new tag. In addition, we'll also provide a SHA1 hash for peace of mind. Fixes #17
.travis.yml
Outdated
skip_cleanup: true | ||
on: | ||
branch: master | ||
repo: SeanPrashad/supernova |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
repo: SeanPrashad/supernova | |
repo: 0xazure/supernova |
I think this slipped through during testing, but I know it was complicated flipping between projects and branches.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @seanprashad awesome job on this! I know how much testing and troubleshooting you had to go through on Travis to get this working, so I really appreciate all the work you've put in.
It's super exciting to get automated build artifacts added to GitHub releases, because this will let us distribute precompiled source binaries to many different platforms in a lot of different packaging methods.
Thanks again! 🎉
Fixes #17: Automatically publish artifacts to GitHub
This PR allows successful Travis builds to publish the
target/release
directory to Github releases for Supernova.