I want to use a gtk theme that isn’t in the NixOS packages. I want to know if i can configure home manager to download the zip and extract it into the ~/.themes folder. I would then tell gnome to use that theme through dconf.
Sure, see the
home.file option. Though the proper location is
~/.local/share/themes these days.
Thanks for the reply but i still don’t understand. With the home.file option i can set the text content of specific files but i need to extract the contents of a tar.gz file to a certain folder.
And i can’t use gtk.theme.package because there isn’t a package for this particular theme.
home.file also accepts directories. And you can create your own packages (derivations).
fetchzip function will take an URL pointing to an archive and produce a derivation containing the unpacked content.
gtk.theme.package, you will need to move the data to
$out/share/themes so doing something like https://github.com/NixOS/nixpkgs/blob/704f9f8a16d3fc57087a52a7b03ad16bd1dbd78f/pkgs/data/themes/e17gtk/default.nix might be easier.
Thank you very much for all your help. I did some research and was able to create my own packages for the GTK and icon themes. I wasn’t able to declare the shell theme so i have to select it manually but it’s still a great improvement.