i use flakes, that means i dont need nix.channel.enable, right..? channels=/=flakes, yeah..?
well, there is a .nix-profile file and a .nix-defexpr folder that randomly (re)appear (after deletion) in my $HOME with (empty) channels and (full) channels_root subfolders in it that are also seem to be dead symlinks. there are also these warnings i get on every update (with the option above set to false):
warning: /root/.nix-defexpr/channels exists, but channels have been disabled.
warning: /nix/var/nix/profiles/per-user/root/channels exists, but channels have been disabled.
warning: /root/.nix-defexpr/channels exists, but channels have been disabled.
Due to https://github.com/NixOS/nix/issues/9574, Nix may still use these channels when NIX_PATH is unset.
Delete the above directory or directories to prevent this.
my $NIX_PATH is nixpkgs=flake:nixpkgs, which was automatically set (?). is it okay to delete those (aforementioned) directories..? or should i just not touch that option..? these warnings dont happen without the option. also, was i supposed to disable that option immediately (after switching to flakes), cos i forgot, so its a problem now..?
okay, this known issue was closed. but it is still not clear to me - is this a normal, expected behaviour in the form of a warning, then..? meaning it wasnt solved, actually..? which then means that i do have to delete those lingering directories, right..?
thanks!!!
P.S. sorry if i missed something obvious… im not good at understanding htings…
It’s telling you your system isn’t completely free of channels, despite you setting the option, unless you delete those directories. If you haven’t set NIX_PATH in a way so that <nixpkgs> goes somewhere other than channels, deleting them might still cause a problem, but it sounds like you have, so deleting them should be fine.
i deleted $HOME/.nix-profile, $HOME/.nix-defexpr/ and the contents of /nix/var/nix/profiles/per-user/root/ (or should i also delete ../per-user/, there is nothing besides an empty root/ folder there?). also, my (other) /root/ folder (in /) is empty (?) when i tried cd / and sudo ls root/ there, so i didnt touch it. the dead symlinks that i mentioned are still there, though, in the /nix/store/…
anyway, the warnings are gone now and these folders are no longer being created (again), so thank you!!!
edit: SORRY i know this is gonna bump it, but i just wanna share something similarly interesting (this is for the future readers if my vaguely titled OP comes up first in search results…):