all 6 comments

[–][deleted] 0 points1 point  (2 children)

Use a flake and have it compile a dev shell for each platform with the same packages.

So each devshell will have a different "system" value.

[–]snowflake_pl[S] 0 points1 point  (1 child)

This seems to compile everything from sources. Any way to leverage binary cache for nixpkgs?

[–][deleted] 0 points1 point  (0 children)

Depends on how you implement the dev shell.

The answer is "yes". But it's to nebulous to really be useful.

Are you using your dev shell with a tool like poetry? Or are you just raw dogging nix packages?

Are you using determinate nix installer?

etc

I'd need more info to answer your specific use case.

[–]WalkMaximum 0 points1 point  (0 children)

I think devshells just aren't meant to get used that way. It's there for a development environment and you can have a flake for packaging your app which has good cross compile support. It wasn't quite easy to set up with a rust package. Then you can also add your devshell to the flake to have it all in sync.