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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(infra): introduce automated publishing #67

Merged
merged 16 commits into from
Jan 25, 2022
Merged

Conversation

miraclx
Copy link
Contributor

@miraclx miraclx commented Jan 24, 2022

This PR introduces a CI job that automates versioning and publishing borsh-rs crates to crates.io.

Here's what the tag page should look like:

Screenshot_20220125_183624

Here's what the release page should look like:

Screenshot_20220125_184422

README.md Outdated Show resolved Hide resolved
.github/workflows/rust.yml Outdated Show resolved Hide resolved
@matklad matklad enabled auto-merge (squash) January 24, 2022 15:49
@matklad
Copy link
Contributor

matklad commented Jan 24, 2022

Kicked auto-merge -- let's fix nits after we make sure the thing works as intended.

@austinabell
Copy link
Contributor

Unversioning everything to have all of this happen in a separate PR? I'm a little confused about why this is necessary

README.md Outdated Show resolved Hide resolved
@frol frol disabled auto-merge January 24, 2022 16:15
@miraclx
Copy link
Contributor Author

miraclx commented Jan 24, 2022

@austinabell, unversioning everything in the source code because now all crates share the version in the root Cargo.toml. The version only needs to be updated in one place in a PR and CI fills it in at the time of publish for all the member crates.

@matklad
Copy link
Contributor

matklad commented Jan 24, 2022

I find github releases useful if you want to subscribe to releases.

Hm, yeah, looking around it seems that, eg, serde is doing releases https://github.com/serde-rs/serde/releases, so this is a strong evidence that I am wrong, and that folks do actually find them useful. Than, yeah, we should add "create gh release" to the automation.

@frol
Copy link
Collaborator

frol commented Jan 25, 2022

I have resolved the Travis issue (it was explicitly set in the branch protection rule on github to wait for Travis checks)

@miraclx Please, merge once you feel ready, the PR is unblocked

@miraclx
Copy link
Contributor Author

miraclx commented Jan 25, 2022

Great. I still have some unpushed commits (creating release works, but I'm touching on it a bit so it's WIP). I'll update on the status in a sec.

@miraclx
Copy link
Contributor Author

miraclx commented Jan 25, 2022

This looks good to me now. @frol, @matklad, @austinabell please take a second look.

.github/workflows/rust.yml Outdated Show resolved Hide resolved
@miraclx miraclx merged commit ef2cf84 into master Jan 25, 2022
@miraclx miraclx deleted the automated-publishing branch January 25, 2022 20:53
@miraclx
Copy link
Contributor Author

miraclx commented Jan 26, 2022

Glad to announce: the release passed successfully.

Release Page: https://github.com/near/borsh-rs/releases/tag/v0.9.2

  • Upgrade hashbrown from 0.9 to 0.11. This can breakage in the rare case
    that you use borsh schema together with no-std support and rely on a specific
    version hashbrown of SchemaContainer. This is considered to be obscure
    enough to not warrant a semver bump.

Crate Links

Now we just need to make sure the CHANGELOG stays updated before each new release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants