Why can't I run the phases out of nix develop
?
#697
Replies: 2 comments 1 reply
-
Why would you want to do any building as a part of the dev shell? That makes no sense to me. I doubt craneLib.devShell (and underlying mkShell) even accept some of the arguments you're trying to check. You probably want to create a derivation like in the examples, and build it with |
Beta Was this translation helpful? Give feedback.
-
Hi @Elias-Graf! You might need to explicitly call BUT if you don't define a default devshell, Hope this helps! |
Beta Was this translation helpful? Give feedback.
-
I'm trying to debug a flake (since it doesn't build with
nix build
, but does when runningcargo build
inside the dev shell), by executing the exact phases. But the devShell environment seems to be different from the build environment. For example, none of the phases seem to be populated:I'm unsure if this is a general nix concept I'm not understanding, but I'm pretty sure that I could execute
eval "$buildPhase"
when building a simple "Hello World C" flake.My flake is pretty much the one from the simple template I think, but here is the shell part if it's of any use:
Help and pointers greatly appreciated.
In case anyone is interested, what isn't working when running
nix build
: Pretty sure the issue is that the translation files do not get copied to the build environment due to thecleanCargoSource
. But I would like to confirm that before just trying, so I can learn something. Thus, I'm trying to get the phases to work, which possible might get me thesrc
if I run unpack(?).Beta Was this translation helpful? Give feedback.
All reactions