2018-05-28 21:12:29 +02:00
|
|
|
#!/bin/sh
|
2009-08-26 17:00:38 +02:00
|
|
|
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...
|
|
|
|
}
|
2018-12-08 05:10:45 +01:00
|
|
|
# Don't mess with /etc/drirc. Mesa now installs the defaults as
|
|
|
|
# /usr/share/drirc.d/00-mesa-defaults.conf. We won't protect that
|
|
|
|
# as a .new file as it shouldn't be modified. Create /etc/drirc if
|
|
|
|
# you need local overrides.
|
|
|
|
#config etc/drirc.new
|