Nix: It’s easy to miss that nix-channel has different contexts

Created on 21 Feb 2016  Â·  6Comments  Â·  Source: NixOS/nix

(copied over from nixpkgs, https://github.com/NixOS/nixpkgs/issues/7113#issuecomment-186664610)
It took me a few hours of head scratching to find out, that nix-channel needs to be called as root to change the system channel. In hindsight that’s obvious, but it seems easy to miss.

I’m aware that this is a nix thing, but it mostly is of concern to NixOS I guess.

How about a message “switched to / added channel foo for user bar”? Since it’s an instant command I think it makes sense to break the rule of silence for that.

Most helpful comment

Why isn't channel configuration part of configuration.nix? It is configuration afterall.

All 6 comments

I had the same problem, when I started using NixOS. Couldn't understand why my nixos-rebuild wasn't updating my system.

Good thing is, channels are going away with new cli.

I have yet to see a viable replacement proposal! Curious what will replace them :)

On Feb 29, 2016, at 15:27, Domen KoĹľar [email protected] wrote:

Good thing is, channels are going away with new cli.

—
Reply to this email directly or view it on GitHub.

Why isn't channel configuration part of configuration.nix? It is configuration afterall.

Good thing is, channels are going away with new cli.

@domenkozar is this still happening?

Channels will be replaced by flakes, so I'll close this.

Was this page helpful?
0 / 5 - 0 ratings