-
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
Add a Nix Flake #2345
base: master
Are you sure you want to change the base?
Add a Nix Flake #2345
Conversation
which for some reason catches this where regular `cargo fmt` misses it
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've got nothing to do with the project, but came here looking for a flake.nix or default.nix, so thought I'd review. Looks good to me, just some minor cleanups.
I've also used the nix flake, and it worked great! I was able to install it into some local flakes using the following dev shell:
I don't love that the binary provided through the flake is Also, one small suggestion on using |
Same, definitely fixable, probably best to make an extra derivation that wraps -cli and -standalone? Not quite sure how
Doesn't work with property paths afaict. |
Description of Changes
Create a Nix flake so that SpacetimeDB is to some degree usable via nix :^)
Also formatted the single not-properly-formatted source file in the codebase out of habit (I can remove this if desired)
As-is the binaries it creates are the package names, not sure if that's desired or not.
API and ABI breaking changes
If this is an API or ABI breaking change, please apply the
corresponding GitHub label.
Expected complexity level and risk
How complicated do you think these changes are? Grade on a scale from 1 to 5,
where 1 is a trivial change, and 5 is a deep-reaching and complex change.
2
This complexity rating applies not only to the complexity apparent in the diff,
but also to its interactions with existing and future code.
I did my best to make it as low-maintenance as possible. Unless new binaries get added, or their dependencies change this should keep working indefinitely. And in case that happens I tried to make the changes required as minimal as possible (cf. lines ~105 in flake.nix)
If you answered more than a 2, explain what is complex about the PR,
and what other components it interacts with in potentially concerning ways.
n/A
Testing
Describe any testing you've done, and any testing you'd like your reviewers to do,
so that you're confident that all the changes work as expected!