Cheatsheet: Difference between revisions
m →Using override with nix-build: Highlight shell commands containing nix expression as "console" instead of "nix": we do that in a few other places, so now everything's consistent + otherwise there are too many colors on one line. If you think this should be reverted, you will also need to turn on "nix" highlight in a few other places for consistency |
GregoryPower (talk | contribs) update subsection "upgrading invdividual packages to a different channel" so it can be easier for newer users of nix-channel usage |
||
| Line 262: | Line 262: | ||
For example one can have both the unstable and stable channels on system root: | For example one can have both the unstable and stable channels on system root: | ||
< | <syntaxhighlight lang="console"> | ||
$ sudo nix-channel --list | $ sudo nix-channel --list | ||
nixos https://nixos.org/channels/nixos- | nixos https://nixos.org/channels/nixos-25.11 | ||
nixos-unstable https://nixos.org/channels/nixos-unstable | nixos-unstable https://nixos.org/channels/nixos-unstable | ||
</ | </syntaxhighlight> | ||
and the following in <code>configuration.nix</code>: | update the channels using the following command:<syntaxhighlight lang="bash"> | ||
$ sudo nix-channel -update nixos nixos-unstable | |||
</syntaxhighlight>and the following in <code>configuration.nix</code>: | |||
<syntaxHighlight lang="nix"> | <syntaxHighlight lang="nix"> | ||