summaryrefslogtreecommitdiffstats
path: root/development/diakonos/doinst.sh
diff options
context:
space:
mode:
author Martin McConnell2014-01-13 00:46:59 +0100
committer Erik Hanson2014-01-30 06:21:00 +0100
commit444729b3deef904dfec2a3862d48530b57675141 (patch)
tree412a232a6d5bbeb77ba6d7011d932d50ce5e695c /development/diakonos/doinst.sh
parent6209cf0706fd85537c8fe5528cea5ab54f2c635c (diff)
downloadslackbuilds-444729b3deef904dfec2a3862d48530b57675141.tar.gz
development/diakonos: Added (advanced console text editor).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'development/diakonos/doinst.sh')
-rw-r--r--development/diakonos/doinst.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/development/diakonos/doinst.sh b/development/diakonos/doinst.sh
new file mode 100644
index 0000000000..9d207adff1
--- /dev/null
+++ b/development/diakonos/doinst.sh
@@ -0,0 +1,15 @@
+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/diakonos.conf.new
+