mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-20 12:07:53 +03:00
8f91e87ded
Packages often run gtk-update-icon-cache to include their icons in themes’ icon cache. However, since each package is installed to its own prefix, the files will only collide. For that reason we are removing the icon-theme.cache from applications. Previously, we did that in hicolor-icon-theme setup hook but, since it is actually gtk3’s utility that creates the cache, we thought it would be appropriate to let its setup hook handle the clearing.
14 lines
297 B
Bash
14 lines
297 B
Bash
# shellcheck shell=bash
|
|
|
|
# Populate XDG_ICON_DIRS
|
|
hicolorIconThemeHook() {
|
|
|
|
# where to find icon themes
|
|
if [ -d "$1/share/icons" ]; then
|
|
addToSearchPath XDG_ICON_DIRS "$1/share"
|
|
fi
|
|
}
|
|
|
|
# I think this is meant to be a runtime dep
|
|
addEnvHooks "${hostOffset:?}" hicolorIconThemeHook
|