Skip to content

CI: Fix semver checks on publish #44

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

Merged
merged 6 commits into from
Mar 24, 2025

Conversation

joncinque
Copy link
Contributor

Better option than #43

Problem

The semver checks step during publish is broken because it's simply passing in the folder, but there's some additional work needed to decompose it into a manifest path.

Summary of changes

Make the manifest path correctly

#### Problem

The semver checks step during publish is broken because it's simply
passing in the folder, but there's some additional work needed to
decompose it into a manifest path.

#### Summary of changes

Similar to many other repos, add a semver script which will pull out the
manifest given a path.
@joncinque joncinque requested a review from febo March 21, 2025 18:21
@@ -68,7 +68,7 @@ jobs:
run: pnpm zx ./scripts/rust/test.mjs "${{ inputs.package_path }}"

- name: Check semver
run: pnpm rust:semver ${{ inputs.package_path }} --release-type ${{ inputs.level }}
run: pnpm rust:semver --manifest-path "${{ inputs.package_path }}/Cargo.toml" --release-type ${{ inputs.level }}
Copy link
Contributor

@febo febo Mar 21, 2025

Choose a reason for hiding this comment

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

This will work for crates > 0.x. Not sure if you would like to update the script with the latest "fix": https://github.com/anza-xyz/pinocchio/blob/main/.github/workflows/publish.yml#L52-L81

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure, done!

Copy link
Contributor

@febo febo left a comment

Choose a reason for hiding this comment

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

Looks great. Last tiny bit that I forgot to mention on my previous comment. You can bring back the level/version input options as well: https://github.com/anza-xyz/pinocchio/blob/main/.github/workflows/publish.yml#L19-L36

Then you will also need to check for the level and version values: https://github.com/anza-xyz/pinocchio/blob/main/.github/workflows/publish.yml#L129-L133

@joncinque
Copy link
Contributor Author

Can we just do that in a separate PR? I don't see the value in it, and it's unrelated to this PR

@joncinque
Copy link
Contributor Author

Oh I see, it's in all the others, ah ok. I'll do it in all of them

@joncinque
Copy link
Contributor Author

Ok, should be good for another look

Copy link
Contributor

@febo febo left a comment

Choose a reason for hiding this comment

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

👌

@joncinque joncinque merged commit b503b24 into solana-program:main Mar 24, 2025
15 checks passed
@joncinque joncinque deleted the semveronpub branch March 24, 2025 21:49
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.

2 participants