And exactly here the misconception starts. It does not create a “derivation”. It just mimics an environment that can be used to build a given derivation.
And as pointed out in How to use `nix develop` within a GitLab CI pipeline? - #2 by NobbZ, it is possible to use nix develop
in CI.
CI Services that allow you to change your shell for a job/step with a custom command, can use nix develop
even as a “shell”.
Though you will never actually able to “build” and “install” something that is like what you enter with nix develop
, as it simply isn’t able to set env vats some how.
Anyway. Most if not all of the posts since What would you like to see improved in Nix cli experience? - #10 by nixinator are probably off topic in this thread, and I’d ask @moderators to split them out.