-
Notifications
You must be signed in to change notification settings - Fork 183
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
Added scheduled release workflow #461
Conversation
Can this tool also bump the versions to a dev version after publishing? |
For updating |
I didn't think that is necessary. Is there any reason for doing this? |
I'm not sure if it's necessary, but I've observed it happening here. |
The tool now updates the As you can see in that commit, only the changed packages got released. The next run would update to |
This is really nice :) So, I know it doesn't update the version to add a Other than that, does it do everything on the checklist? If so, then I could maybe be persuaded that not adding a |
It does everything except for the following things:
Just doing The work on cargo-workspaces needed for this is not much and I can do it, but i just don't understand the reason for it. |
So, the reasoning for a How does adding the suffix complicate the usage of the crates? If someone is using the git repo as a dependency, then they don't require a version. If they publish, then there has to be a crates.io release of the version they need. Which is not the same as the git master. |
Why not update |
Yeah, but imagine if the releases are non-breaking. For example, I would use crate
I would want to develop my crate against the git master but since But I understand that this basically comes down to the general preference of the maintainer and if you want it I will add it. |
Well, I don't think cargo looks at version when pulling a git dependency. So it doesn't matter what the version is on master. (-dev or not). Also, while the releases follow semver, the master branch does not. So using master as a dependency but falling back to a version could theoretically break. (In fact, the only time we are guaranteed to not break by semver is if master would only be bumping to a patch version. E.g. if we are relying on new features in master) If it's not a lot of work, it would be awesome if you could add it. Thanks :) |
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.
We probably don't want the ".0" in the -dev.0
. Other than that LGTM
@nikomatsakis what do you think of this? I think the only user-visible change here is we no longer will be updating the RELEASES.md. We also need to set up the tokens.
#461 (comment) |
@Mcat12 I did miss your comment, sorry. We did discuss this in the meeting too. I don't think having people update the |
It's not a big deal to update it. Just a |
Ooh then that would be ideal. (I do think it is a nice thing to have. Even if it's a little bit more work) |
I have previously looked into Maybe something similar can be added with |
I was wrong. If we want to use this generally, we wouldn't know the version until |
We could stay one version ahead in the changelog. Then we just add a section for the next version when bumping post-release. Ex: after releasing 0.10, add a 0.11 section to the changelog. |
So, I had to add some manual steps with |
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.
I have no strong opinion about this setup but I'd like to request a review from @pietroalbini or someone else from @rust-lang/infra
Master is failing due to recent merge of @Mcat12's PR |
It looks like the PR wasn't fully up to date with master and the panic tests which were in master reference the old |
We should definitely have bors |
I fixed master and restarted the checks |
@pietroalbini @nikomatsakis Only the cargo token is left to be added and this thing can start publishing. |
OK. I'm debating if I should make a "dummy user" to |
Since crates.io tokens are kind of coarse-grained :) |
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.
We probably don't want the ".0" in the -dev.0.
Not sure if this was seen/addressed. If so, then LGTM. Otherwise, this should be changed.
I have been trying to find some standardized info on the pre-release tags but am unable to. AFAIK, the pre-release tags should always be tagged as This has been my experience and the other release tools which support prereleases. But as I said, I can't find this written down anywhere. |
@pksunkara See the "Backus–Naur Form Grammar for Valid SemVer Versions" section at https://semver.org/ Specifically, the |
Let me rephrase, yes it is possible to write anything for the pre-release, but there is a convention majority people follow and I was describing it. I built the cargo-workspaces prerelease functionality around this convention. I don't think I can easily fix this. |
I have always seen it as just |
Yeah, the assumption behind it was that pre releases will always be numbered since they can be multiple with the same tag. |
The difference here seems to be that we never intend on publishing the |
That'd be the best way, even though I'd lean torwards a bot account managed by the infra team (I can set it up). |
@pietroalbini a bot sounds better, yes |
fyi, @pietroalbini was looking into creating an infra bot to host the token, but he ran into some problem that he's trying to resolve. |
Added the |
What's the issue? Just curious. |
The issue we had before was that the bot account we created got flagged, so we talked with GitHub to get it fixed. Now I need to coordinate with Niko to add ownership of the crates to the bot. |
As per the discussion on Zulip, here's the action that schedules and releases chalk every Sunday.
I used cargo-workspaces for this which means if there are no changes in a week, a version will not be released. It also intelligently releases only the changes instead of everything.
You need to add 2 secrets in github for this to work:
You can see an example release commit here
cc @jackh726 @flodiebold @nikomatsakis
I saw your message about asking me to also integrate bors-ng. While I did do that for https://github.com/clap-rs/clap, I am not sure if I can do that here without having access to settings. I could just create/edit the related config for it but it would be hard for me to debug.
EDIT: I realized that I would need to update
Cargo.lock
as well. Can someone confirm? While I would like to just runcargo build
to update theCargo.lock
, but I think it would also update other deps, right? Is there an option to update only the local crates? I am not sure how to proceed on this.Does running
cargo update -p {crate_name}
for each crate in workspace fix it?