I just took a look at the nixos-unstable branch on github and noticed that it is currently using emacs26
however, on my machine I seem to have emacs25 installed. What’s going on here?
More generally:
The nix community already seems pretty heavily invested in git (use github for pull requests etc.). Why have a channel mechanism that does not seem to use git?
My understanding of nix channels is pretty limited but I think I may know the answer here.
Each nix channel is checked out on NixOS’s build servers. The servers compile the software in the channel and run tests. If the tests succeed (and at least if certain set of the software in the channel compiles successfully), the channel is published and everyone’s machine gets it.
Basically, the git may have version 26 in the master branch, which the server checked out and started running tests. Let’s say that hypothetically GCC is broken in the master branch of nixpkgs, so the entire branch is rejected and the old version remains as the “unstable” branch. This will continue until GCC is marked broken or is fixed, which will then allow the tests to succeed and will let nixpkgs update.
IDK if this makes any sense or is even correct. Hopefully someone knowledgeable can explain it better.
Once is a while a channel gets “stuck” until somebody fixes it. If that happens, go to http://howoldis.herokuapp.com/ to get more information about the failing builds.
this is the repo we should look to if we want to see what is currently available in the channels (and what will be installed from a given channel, which is tracked by the different branches of the channel).
Channel mechanism relies on Git! But it is not visible for end user. Should it? If all you don’t like is nix-channel utility, then good news for you, it is replacable:
nix-channel --add https://nixos.org/channels/XXXX can be replaced with git clone -b XXXX https://github.com/nixos/nixpkgs-channel
nix-channel --list is essentially ls now
nix-channel --update can be replace with git pull
nix-channel --rollback GENERATION can be replaced with
@danbst
Yes, what I dislike about nix-channel is that it does not expose the bare git repository to the user. If I want to use the nixpkgs from my git repository in my nixos system configuration, won’t I have to do something like
let pkgs = /path/to/my/nixpkgs
I just want my system to know that the canonical nixpkgs lives in some specific place, and have that place be managed by a git repository that I can interact with using normal git commands. As far as I can tell, I’ll still need to be explicit about which nixpkg im using unless I use the channel mechanism.