When running this command, it looks for installed package, search if upstream (not nixpkgs, but the software upstream) has a newer version and report it. That’s handy to find updates for software we are using.
which is part of a nixos-rebuild build --upgrade | nix-output-monitor ; nvd $currentsystem $builtsystem with a prompt asking me if I want to upgrade.
If I don’t, channel is rollbacked.
I guess that reusing the appstream metadata stuff for Software Center, it should be possible to build a true command that will ask upstream in reasonable scenarios, e.g. proper upstream metadata.
That tool essentially replaces the need to run guix refresh locally, since it monitors when any package in Nixpkgs can be updated. Assuming of course it knows how to update it.
I personally instantiate the system locally and diff against repology’s database. I’m using very hacky bash and jq. Would be nice to have a better maintained tool Example session (it compares against staging local branch):
Do I need to compile and run this locally to get it to work with flakes?
It should work as is. I’m a bit surprised you don’t see out / err output on command failures. Can you post the full logs including the command you run?
You can also add -v to see the failure details. My session looks like:
$ nix run github:trofi/nix-olde -- -v
Fetching 'installed'
Fetching 'repology'
Fetching 'available'
...
333 of 1941 (17.16%) installed packages are outdated according to https://repology.org.
...
And any plans on adding this to the nix package repo?
I have no concrete plans but I don’t mind if anyone packages it.
nix-olde was not able to instantiate your system derivation: neither via /etc/nixos/flake.nix (not a flake-based system?) nor via nix-instantiate '<nixpkgs/nixos>' -A system (missing nixos-config). Do you know where any of those comes from on your system?
I may be misunderstanding, but my flake is saved in ~/.dotfiles/flake.nix and my configuration.nix file is in ~/.dotfiles/nixos and my home-manager config is in ~/.dotfiles/home/home.nix.
I tried creating a symlink to it in /etc/nixos, but that gives me the following errors:
INFO: err> error: 'flake.nix' file of flake 'path:/etc/nixos?lastModified=1717976976&narHash=sha256-Uuuq80LpGYXBikTvEoMuGo2b/l8f11dJhvahM9j2Stg%3D' escapes from '/nix/store/i6agp0a5zqm402xr2jl2h7xaci34pybz-source'
INFO: Failed running ["nix", "--extra-experimental-features", "nix-command", "--extra-experimental-features", "flakes", "flake", "archive", "/etc/nixos", "--json"]: ExitStatus(unix_wait_status(256))
INFO: err> error: 'flake.nix' file of flake 'path:/etc/nixos?lastModified=1717976976&narHash=sha256-Uuuq80LpGYXBikTvEoMuGo2b/l8f11dJhvahM9j2Stg%3D' escapes from '/nix/store/i6agp0a5zqm402xr2jl2h7xaci34pybz-source'
My setup may not be vanilla enough, but I just wanted to pass the feedback on. Looks like a cool program. I’m honestly surprised that it isn’t baked into NixOS.