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/openjdk17/logging.properties.new config etc/openjdk17/net.properties.new config etc/openjdk17/sound.properties.new config etc/openjdk17/management/jmxremote.password.template.new config etc/openjdk17/management/jmxremote.access.new config etc/openjdk17/management/management.properties.new config etc/openjdk17/security/policy/unlimited/default_local.policy.new config etc/openjdk17/security/policy/unlimited/default_US_export.policy.new config etc/openjdk17/security/policy/limited/default_US_export.policy.new config etc/openjdk17/security/policy/limited/default_local.policy.new config etc/openjdk17/security/policy/limited/exempt_local.policy.new config etc/openjdk17/security/java.policy.new config etc/openjdk17/security/java.security.new config etc/openjdk17/sdp/sdp.conf.template.new if [ -x usr/bin/update-desktop-database ]; then chroot . /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 fi if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then if [ -x usr/bin/gtk-update-icon-cache ]; then chroot . /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1 fi fi