config() { NEW="$1" OLD="$(dirname $NEW)/$(basename $NEW .new)" # If there's no config file by that name, mv it over: if [ ! -r $OLD ]; then mv $NEW $OLD elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then # toss the redundant copy rm $NEW fi # Otherwise, we leave the .new copy for the admin to consider... } config etc/fonts/conf.avail/65-droid.conf.new # Update X font indexes and the font cache: if [ -x ./usr/bin/mkfontdir ]; then chroot . /usr/bin/mkfontscale /usr/share/fonts/TTF chroot . /usr/bin/mkfontdir /usr/share/fonts/TTF fi if [ -x ./usrF/bin/fc-cache ]; then chroot . /usr/bin/fc-cache -f /usr/share/fonts/TTF fi