-
-
Notifications
You must be signed in to change notification settings - Fork 13.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Should nixos-rebuild switch --upgrade update all channels? #44360
Comments
It seems like the upgrade code has functionality for auto-upgrading other channels, but only if a It might be better to add a nixos option or nix-channel flag (--add --update-on-rebuild) to make it easier to add and manage that file for channels instead of changing the default behavior. |
The behaviour i expect is even documented in the unofficial nixos.wiki: Since it would be a breaking change, just change it for the next release? |
Thank you for your contributions. This has been automatically marked as stale because it has had no activity for 180 days. If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity. Here are suggestions that might help resolve this more quickly:
|
Hello, I was a bit surprised with this too. Maybe this should be futher documented or we should have an option in auto update feature to refresh all channels? Or did anyone find a workaround for this? Thanks |
I marked this as stale due to inactivity. → More info |
Issue description
I expected it would update all channels and struggled with problems due to other channels are not updated.
The docs are clear that it only updates the nixos channel. https://nixos.org/nixos/manual/#sec-upgrading
https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/installer/tools/nixos-rebuild.sh#L197
I had to use
nix-channel --update
in addition to rebuild the system.So i suggest to change this to actually update all channels.
In 2015, this change was already proposed by @aszlig, but @edolstra had concerns that users might not want to update all channels. What do you think now? #7349 (comment)
Maybe in that case such users can use
nix-channel --update nixos; nixos-rebuild switch
and a user that just want to update everything runsnixos-rebuild switch --upgrade
?Steps to reproduce
nixos-rebuild switch --upgrade
Technical details
"x86_64-linux"
Linux 4.14.59, NixOS, 18.03.133017.0e55dde2eaa (Impala)
no
yes
nix-env (Nix) 2.0.4
"nixos-18.03.133023.18401b99f3f, nixos-hardware, nixos-unstable-18.09pre147850.2428f5dda13"
/nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs
The text was updated successfully, but these errors were encountered: