about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/gtk/hooks/gtk4-clean-immodules-cache.sh
blob: 49f7051aabb6f6b92018f5f0a49cc32d4f151d45 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
# shellcheck shell=bash

fixupOutputHooks+=(_gtk4CleanComments)

# Clean comments that link to generator of the file
_gtk4CleanComments() {
    local f="${prefix:?}/lib/gtk-4.0/4.0.0/immodules.cache"
    if [ -f "$f" ]; then
        sed 's|Created by .*bin/gtk-query-|Created by bin/gtk-query-|' -i "$f"
    fi
}