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

Rewrite and simplify crates.io publishing actions #724

Merged
merged 3 commits into from
Jun 4, 2024

Conversation

Shnatsel
Copy link
Contributor

@Shnatsel Shnatsel commented Jun 3, 2024

This changes the workflow to be triggered by a tag, rather than create a tag automatically. We need the tag to be created by a human rather than by Github Actions so that cargo-dist workflows that publish binaries would work properly. (I had to do some manual fixup to build binaries for the latest release).

This also removes the --allow-dirty flag that prevents attribution to a specific commit and is known to cause issues for links in the way our documentation shows up on crates.io, previously attempted in #719

Drops cache because the check before publishing uses latest versions from crates.io rather than what we have in Cargo.lock, so caching isn't do much there. Also, clean builds have less of a risk of running into incremental compilation bugs in the compiler, and we run this workflow rarely enough that execution time is not a concern.

@Shnatsel Shnatsel requested a review from a team as a code owner June 3, 2024 12:42
Shnatsel added 3 commits June 3, 2024 13:43
Signed-off-by: Sergey "Shnatsel" Davidoff <[email protected]>
Signed-off-by: Sergey "Shnatsel" Davidoff <[email protected]>
@Shnatsel
Copy link
Contributor Author

Shnatsel commented Jun 3, 2024

I've tested this on a fork but it didn't have a token so I can only be sure this triggers correctly on a tag, and not about any of the more involved stuff. But it's still cargo publish and we aren't making any untracked files in the package directory so it should work fine.

@Shnatsel Shnatsel merged commit 9de191c into CycloneDX:main Jun 4, 2024
14 checks passed
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.

1 participant