this is a continuation of https://discourse.nixos.org/t/can-i-use-flakes-within-a-git-repo-without-committing-flake-nix/18196/37?u=srghma
IF I enable nix flakes
AND I am in the in the git repo
I found the following behavior
IF I do
nix build .THEN nix will try to find the type of directory.
- IF
./.gitTHEN type isgit- IF
./.something-else-dont-knowTHEN type ismercurial- ...
- IF nothing is found THEN type is
pathbut I can force nix to use specific type by using
nix build git+file:.ornix build path:.
QUESTION:
- what is the difference?
- what is
self-contained/hermetic evaluation? git-flake-evaluationishermetic, but ispath-flake-evaluationhermetic?- does
nix build git+file:.have some additional caching, thatnix build path:.doesnt have? - why not make
nix build .just equal tonix build path:., instead of thisfind type automaticallybehavior, described above (Because: what problem its trying to solve? The problem, solutions to which require all these weird behaviors, like unsolicitedgit addbehind the scenes? But I can easily get around/silence it withpath:.? This design is so weird, reason is so shady)