Open evils opened 9 months ago
though the issue here isn't that it can't resolve links, but that it treats it as different before and after resolving it?
i was pointed here as the source of this particular example's error
with the explanation that for some parts of this build it looks for pkgs
in the parent directory relative to the given nixpkgs
with ..
, which loses the link to the current directory
while presumably something still refers to the path given in the command's argument
i suspect this could be resolved by always sanitizing inputs with the equivalent of realpath
and am of course oblivious to any unintended consequences that would have :)
Describe the bug
nix-build -I nixpkgs=/media/cruft/nixpkgs-link '<nixpkgs/nixos>' -A config.system.build.isoImage -I nixos-config=iso.nix
results inerror: The option 'system.installer.channel.enable' in '/media/cruft/nixpkgs-link/nixos/modules/installer/cd-dvd/channel.nix' is already declared in '/media/cruft/nixpkgs/nixos/modules/installer/cd-dvd/channel.nix'.
note that the two paths there are different,
nixpkgs-link
is a link tonixpkgs
Steps To Reproduce
Steps to reproduce the behavior:
iso.nix
).txt
) iso.txt/media/cruft/nixpkgs
)/media/cruft/nixpkgs-link
)nix-build -I nixpkgs=/media/cruft/nixpkgs-link '<nixpkgs/nixos>' -A config.system.build.isoImage -I nixos-config=iso.nix
nixpkgs=
set to the direct path and see it workExpected behavior
nix-build
to follow non-looping symlinks indefinitelyNotify maintainers
no idea who to tag here, i don't even know if this is the right repo for reporting this issue
Metadata
Add a :+1: reaction to issues you find important.