triggers/gtk-icon-cache.trigger
raw| 1 | #!/bin/sh |
| 2 | |
| 3 | if command -v gtk-update-icon-cache >/dev/null && test -d "$1/exports/share/icons/hicolor"; then |
| 4 | cp /usr/share/icons/hicolor/index.theme "$1/exports/share/icons/hicolor/" |
| 5 | for dir in "$1"/exports/share/icons/*; do |
| 6 | if test -f "$dir/index.theme"; then |
| 7 | if ! gtk-update-icon-cache --quiet "$dir"; then |
| 8 | echo "Failed to run gtk-update-icon-cache for $dir" |
| 9 | exit 1 |
| 10 | fi |
| 11 | fi |
| 12 | done |
| 13 | fi |