snowfallorg / nix-software-center

A simple gtk4/libadwaita software center to easily install and manage nix packages
GNU General Public License v3.0
560 stars 16 forks source link

"Installed" tab empty #7

Open NobbZ opened 1 year ago

NobbZ commented 1 year ago

I added my flake and the software center doesn't list anything installed.

vlinkz commented 1 year ago

As of right now it only detects packages installed in one configuration.nix, so if packages are installed in imported files, they won't be detected at the moment

NobbZ commented 1 year ago

So there is basically no flake support?

vlinkz commented 1 year ago

There is flake support. Just at the moment it only detects one configuration file and its options (not flake.nix), and then the location of the flake.nix file so it knows where to rebuild.

NobbZ commented 1 year ago

But which configuration file does it take from the flake then?

vlinkz commented 1 year ago

You have to specify it in either the welcome screen, the preferences, or in the nix-data module. For example, if I have my /etc/nixos directory containing flake.nix and configuration.nix, then in the welcome screen, I'd specify my configuration file as /etc/nixos/configuration.nix and my flake file as /etc/nixos/flake.nix. At some point, I'll probably try to make it so everything is detected from just the flake.nix file, but that's going to take a lot of work to implement.

NobbZ commented 1 year ago

What do I need to specify the flake for then? I could just specify that one configuration file.

Seems as if I totally misunderstood this tool.

vlinkz commented 1 year ago

Flake is specified so that `nixos-rebuild --flake /path/to/flake#profile' is called properly when upgrading or adding a package to the configuration