Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
nix-direnv
A fast, persistent use_nix/use_flake implementation for direnv [maintainer=@Mic92 / @bbenne10]
We added two inputs, the first is nixpkgs which lets us specify which version of nixpkgs we should use. There are many thousands of packages in the nixpkg repository, and they are updated often so here will use the unstable branch. We also added flake-utils which helps us generalize the flake to support multiple systems, not just Linux.
We added rust-overlay, so we can easily specify different rust versions without relying on nixpkgs to give us what ever rust version in there.
Install direnv and nix-direnv. The second is optional but helps with caching, so I recommend it.
Let's use dive to look at the image. You can use it temporarily with nix shell nixpkgs#dive.
Getting a dev environment setup with rust is usually pretty simple, just use rustup then you're good to go. Using a build tool like Nix can buy you much more for not much extra work. Nix lets you
Install direnv and nix-direnv. The second is optional but helps with caching, so I recommend it.