mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-16 19:50:19 +01:00
f28007bfe3
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
16 lines
376 B
Bash
16 lines
376 B
Bash
|
|
config() {
|
|
NEW="${1}.new"
|
|
OLD="$1"
|
|
# If there's no config file by that name, mv it over:
|
|
if [ ! -r $OLD ]; then
|
|
mv $NEW $OLD
|
|
elif [ "$(md5sum <$OLD)" = "$(md5sum <$NEW)" ]; then
|
|
# toss the redundant copy
|
|
rm $NEW
|
|
fi
|
|
# Otherwise, we leave the .new copy for the admin to consider...
|
|
}
|
|
|
|
config etc/iscsi/iscsid.conf
|
|
config etc/iscsi/initiatorname.iscsi
|