diff options
author | Michael Johnson <youngmug@animeneko.net> | 2010-05-11 22:55:28 +0200 |
---|---|---|
committer | David Somero <xgizzmo@slackbuilds.org> | 2010-05-11 22:55:28 +0200 |
commit | a1c01b57a34588a04b23c5c7b43f299f8e2f10ef (patch) | |
tree | cc128a3e14e92649b09a78beab4592a484e565a9 /system/rkhunter/doinst.sh | |
parent | 489a7e9c0ad15c6ccab91776a15757979faa73fa (diff) | |
download | slackbuilds-a1c01b57a34588a04b23c5c7b43f299f8e2f10ef.tar.gz |
system/rkhunter: Added to 12.1 repository
Diffstat (limited to 'system/rkhunter/doinst.sh')
-rw-r--r-- | system/rkhunter/doinst.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/system/rkhunter/doinst.sh b/system/rkhunter/doinst.sh new file mode 100644 index 0000000000..9a82df242e --- /dev/null +++ b/system/rkhunter/doinst.sh @@ -0,0 +1,14 @@ +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/rkhunter.conf.new |