花 - Hana | Nixos dotfiles. Contribute to mobsenpai/hana development by creating an account on GitHub.
I know that if using flakes nix shell is the right command. But I just want to know that is it normal for legacy commands to not work like that one? nix-env works tho.
Notice the nixpkgs: not found, This is also weird to me.
logs ->
error:
… while calling anonymous lambda
at «string»:1:1:
1| {...}@args: with import <nixpkgs> args; (pkgs.runCommandCC or pkgs.runCommand) "shell" { buildInputs = [ (nix-info) ]; } ""
| ^
error: file 'nixpkgs' was not found in the Nix search path (add it using $NIX_PATH or -I)
at «none»:0: (source not available)
I think this has to do with flakes. If you run something as a flake it doesnt use channels, which is the alternative. The import is looking for it as a channel on the host machine. With flakes its provided as an input.
It looks like nixinfo is explicitly looking for channels to tell you info, like how neofetch would tell you interesting stats. The same does not apply with flakes. There's no "default" upstream package base that can queried by the system.