Desktop icons missing after 'nix-collect-garbage --delete-older-than 2d'

New to Nix, so apologies if this is daft: after a lot of rebuilds (as part of the learning process) I decided to ‘clean’ up…

I ran nix-collect-garbage --delete-older-than 2d, did another rebuild and reset the computer. Now most of the desktop icons are missing.

Programs still open on clicking, and the icons even reappear when they are opened, but apart from the default installed Firefox/Dolphin/Settings icons, and my manually added Application Launcher button, the rest are gone.

  • I was always using the default icons that came on install.
  • I tried adding another icon set to environment.systemPackages in configuration.nix, but the same behaviour persists.
  • I tried adding the breeze theme manually to environment.systemPackages, and it still persists.
  • Moving back to another Generation didn’t roll back the changes (maybe it shouldn’t, but it doesn’t)

Obviously I’ve done something, but Googling around isn’t leading to any workable answers that I can find, so any help would be appreciated.

1 Like

Seems I have done the big dumb-dumb.

I initially installed my packages under the user account section of configuration.nix, but did alter the location to environment.systemPackages just prior to this. With a bit more careful reading, and certain packages only working in that location, I elected to change the others.

So, it occurred to me maybe I only broke the visible ‘shortcut’ to the program, as they did otherwise work; I checked the Application Launcher and the icons are indeed still present on the system.

I’ve simply re-added them to the desktop manually and see no further issue.

I have the same issue on kde plasma.

I have a semi-related issue that packages installed in environment.systemPackages don’t have an icon unless I reboot the system. I’m on GNOME.

Ancient issue; see Gnome Activities icons should appear on app install · Issue #12757 · NixOS/nixpkgs · GitHub and optionally follow symlinks when monitoring files. (#144) · Issues · GNOME / GLib · GitLab.

May have jumped the gun somewhat here - the same issue still occurs after garbage collection, despite the install method for the programs not changing this time.