-
Notifications
You must be signed in to change notification settings - Fork 500
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: add semver_matches
utility function
#1713
Conversation
Hey @casey got some code up to implement the new utility -- please let me know if I'm missing anything, or if you'd like more test cases! |
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.
Looks good! Check out the review comments.
Thanks for the thorough review @casey , I made the changes and squashed to get one commit (I'm a fan of single non-merge commit history). |
While coordinating different programs using `just`, it's often necessary to compare the *versions* of different binaries or utilitiies. Assuming that the utility in question providers a `--version` switch and can reasonably print out a version, being able to match semver of the utility to an expectation is very useful. This commit adds a `semver_matches` utility which utilizes the `semver` crate (https://crates.io/crates/semver) to provide matching functionality to `Justfile`s. Signed-off-by: vados <[email protected]> Co-authored-by: Casey Rodarmor <[email protected]>
Nice, merged! Thank you for the PR! |
Thanks for the help and thorough reviews! :) |
While coordinating different programs using
just
, it's often necessary to compare the versions of different binaries or utilitiies. Assuming that the utility in question providers a--version
switch and can reasonably print out a version, being able to match semver of the utility to an expectation is very useful.This commit adds a
semver_matches
utility which utilizes thesemver
crate (https://crates.io/crates/semver) to provide matching functionality toJustfile
s.Resolves #1712