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

Set the crate version centrally via the workspace #2089

Merged
merged 2 commits into from
Apr 8, 2024
Merged

Conversation

aumetra
Copy link
Member

@aumetra aumetra commented Apr 5, 2024

No description provided.

@aumetra aumetra requested a review from chipshort April 5, 2024 10:29
@aumetra aumetra force-pushed the aw/workspace-version branch from b0d8f92 to f0675a5 Compare April 5, 2024 10:34
Copy link
Collaborator

@chipshort chipshort left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much nicer. I think the devtools/set_version.sh also needs updating (or we just remove it and update the wiki page for publishing)

packages/go-gen/Cargo.toml Outdated Show resolved Hide resolved
@webmaster128
Copy link
Member

I think the devtools/set_version.sh also needs updating (or we just remove it and update the wiki page for publishing)

What happens to the internal versions that use = right now? See the dependencies in check/Cargo.toml.

@chipshort
Copy link
Collaborator

Good point, we do need to keep the version script for those.

@aumetra
Copy link
Member Author

aumetra commented Apr 5, 2024

Tbh the entire release process could be streamlined with cargo-release.

It automatically:

  • bumps all the versions across the workspace (it also keeps locked versions, i.e. =[version], as locked versions)
  • creates Git tags for each crate in the workspace
  • publishes the crates to crates.io

https://github.com/crate-ci/cargo-release

@aumetra aumetra requested a review from chipshort April 5, 2024 11:46
@chipshort
Copy link
Collaborator

chipshort commented Apr 5, 2024

Haven't used cargo-release before, but after trying it out, it looks pretty good. Switching to it would be fine from my side.
If we want to use the tagging feature, we need to update the changelog before running cargo release (see https://github.com/CosmWasm/cosmwasm/wiki/Releasing). Also, we would want to specify something like tag-name = "v{{version}}" to keep the current tag naming.

It would also solve some edge cases the current script has. For example, the script could replace versions of unrelated dependencies that just happen to be the same as our old version.

@aumetra
Copy link
Member Author

aumetra commented Apr 5, 2024

I'm gonna have a look at integrating it. Gonna do that in a separate PR

Because having the entire release process in one, plus edge case avoidance, feels like a pretty worthwhile addition

@aumetra
Copy link
Member Author

aumetra commented Apr 8, 2024

@chipshort Mind giving this a last quick look so we can merge this?

Copy link
Collaborator

@chipshort chipshort left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
The version script will be broken with this merged, but that will become irrelevant with #2090

@aumetra aumetra merged commit cbfd497 into main Apr 8, 2024
29 checks passed
@aumetra aumetra deleted the aw/workspace-version branch April 8, 2024 10:09
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.

3 participants