brew-nix
brew-nix copied to clipboard
pkg files do not install completely
With https://github.com/BatteredBunny/brew-nix/pull/11, I was able to get sf-symbols working and installed, except I was surprised to find that the fonts themselves did not install. I think that this project depends on home-manager to unpack and do the final installation steps for us. This is how home-manager installs the /Applications
folder for our homebrew packages:
https://github.com/nix-community/home-manager/blob/fcf5e608ac65f64463bc0ccc5ea86f2170f20689/modules/targets/darwin/linkapps.nix#L6
Unfortunately, home-manager does nothing for the /Library
and /Resources
folders in our output derivation, but I think they should maybe be handled (or maybe fonts are a special case?).
The main point is that we produce those two folders, but home-manager does nothing with them, even though they are important to have installed.
❯ nix build github:xav-ie/brew-nix/14799b06d60a6dc46b4f68c0e2f9eb4ec33e6c42\#sf-symbols
❯ ls result/Library
Fonts
# ^ this should be installed, but home-manager does nothing with the `Library` and `Resources`
# folders
I was able to find a workaround with this PR:
https://github.com/xav-ie/brew-nix/pull/1
But I am not sure if that is right. Maybe fonts are special? But what if other things are in Library
? It would still not be handled. I was able to figure out the fonts fix by reading:
https://github.com/nix-community/home-manager/blob/fcf5e608ac65f64463bc0ccc5ea86f2170f20689/modules/targets/darwin/fonts.nix
I am not sure what the right way forward is. I think I just don't understand where those two folders are supposed to go. There is a root /Library
folder, just like /Applications
, but what about /Resources
? There is no root /Resources
folder.