1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-11-08 19:46:05 +01:00

fontconfig: Fix missing default fontconfig files (#7045)

This adds the fontconfig's default files to
`home-path/etc/fonts/fonts.conf` and `home-path/etc/fonts/conf.d/*`
This commit is contained in:
Rosario Pulella 2025-05-20 09:22:08 -04:00 committed by GitHub
parent 2097441633
commit 65d2282ff6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 15 additions and 0 deletions

View file

@ -96,6 +96,19 @@ in
# trying to write to a read-only location.
(pkgs.runCommandLocal "dummy-fc-dir1" { } "mkdir -p $out/lib/fontconfig")
(pkgs.runCommandLocal "dummy-fc-dir2" { } "mkdir -p $out/lib/fontconfig")
# Provide fontconfig default files from /etc/fonts/
(pkgs.runCommand "fontconfig-conf" { } ''
dst=$out/etc/fonts/conf.d
mkdir -p $dst
# fonts.conf
ln -s ${pkgs.fontconfig.out}/etc/fonts/fonts.conf \
$dst/../fonts.conf
# fontconfig default config files
ln -s ${pkgs.fontconfig.out}/etc/fonts/conf.d/*.conf \
$dst/
'')
];
home.extraProfileCommands = ''

View file

@ -7,5 +7,7 @@
nmt.script = ''
assertPathNotExists home-path/lib/fontconfig/cache
assertLinkExists home-path/etc/fonts/fonts.conf
assertDirectoryExists home-path/etc/fonts/conf.d
'';
}