nmattia / niv

Easy dependency management for Nix projects
https://github.com/nmattia/niv
MIT License
1.55k stars 77 forks source link

NIV_OVERRIDE path sanitizing broken? #286

Open nomeata opened 3 years ago

nomeata commented 3 years ago

In 0.2.16 I could use this:

~/foo/bar/nix $ NIV_OVERRIDE_baz=$PWD/../../baz/ nix-build

but with 0.2.18 this does not get picked up any more (it silently uses the source specified in souces.json). What works, however, is

~/foo/bar/nix $ NIV_OVERRIDE_baz=$HOME/foo/baz nix-build -A ic-webauthn-cli

It looks like paths with .. are ignored; ideally they’d work, or at worse fail with an error message.

nomeata commented 3 years ago

Ok, all wrong: the difference is whether there is a trailing slash or not. Things break if there is one, it seem.s