mirror of
git://slackware.nl/current.git
synced 2024-12-27 09:59:16 +01:00
037917abe7
a/libblockdev-2.24-x86_64-1.txz: Added. This is required by the new version of udisks2. a/libbytesize-2.4-x86_64-1.txz: Added. This is required by the new version of udisks2. a/ndctl-70.1-x86_64-1.txz: Added. This is required by libblockdev, which in turn is required by the new version of udisks2. a/udisks2-2.9.1-x86_64-1.txz: Upgraded. Thanks to Robby Workman for this update and the deps for it. a/volume_key-0.3.12-x86_64-1.txz: Added. This is required by the new version of udisks2. ap/qpdf-10.0.2-x86_64-1.txz: Upgraded. n/openvpn-2.5.0-x86_64-1.txz: Upgraded. n/php-7.4.12-x86_64-1.txz: Upgraded.
26 lines
929 B
Bash
26 lines
929 B
Bash
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/udisks2/udisks2.conf.new
|
|
|
|
# udisks2 is stupid about testing files before using them. If /etc/crypttab
|
|
# does not exist, it will fill the log with "errors" as it tries to open the
|
|
# nonexistent file. There's really no reason that a system without encrypted
|
|
# volumes should require this file, but nobody upstream cares to fix the
|
|
# problem (and the code's too messy for me to find it), so we have little
|
|
# choice but to trowel over this. (sigh)
|
|
|
|
if [ ! -r etc/crypttab ]; then
|
|
# echo "HEY, EVERYONE SHOULD HAVE A CRYPTTAB!!!" (just kidding)
|
|
touch etc/crypttab
|
|
fi
|