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

Provide a version flag #302

Closed
wants to merge 3 commits into from
Closed

Provide a version flag #302

wants to merge 3 commits into from

Conversation

lucperkins
Copy link
Contributor

@lucperkins lucperkins commented Apr 30, 2024

Pull Request

Summary

Provides a --version flag for the Resonate server, with the current version set in version.json. I'm open to other ways of setting this value, as long as it's in a file somewhere 😄 It could also potentially be set as a variable in flake.nix.

Changes

Adds a version.json file as the canonical place to set the version, adds a --version flag to the CLI, and updates the package definition in flake.nix to properly supply version information during the build process.

Related Issues

This is in response to #301, which is well intentioned but doesn't quite provide the right mechanism.

Testing

nix build
./result/bin/resonate --version
resonate version 0.5.0

Screenshots (if applicable)

N/A

Checklist

  • I have tested my changes thoroughly.
  • My code follows the project's coding standards.
  • I have updated the documentation (if applicable).
  • I have added relevant comments to the code.
  • I have resolved any merge conflicts.

Reviewers

Copy link

codecov bot commented Apr 30, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 58.46%. Comparing base (377c55b) to head (e702585).
Report is 2 commits behind head on main.

❗ Current head e702585 differs from pull request most recent head affdd62. Consider uploading reports for the commit affdd62 to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #302   +/-   ##
=======================================
  Coverage   58.46%   58.46%           
=======================================
  Files         113      113           
  Lines        9775     9776    +1     
=======================================
+ Hits         5715     5716    +1     
  Misses       3693     3693           
  Partials      367      367           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@guergabo
Copy link
Contributor

Since we need the version in a file anyway we will just put the version in the root cobra command instead. Thanks.

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