aboutsummaryrefslogtreecommitdiff
path: root/system/fish/doinst.sh
diff options
context:
space:
mode:
authorPierre Cazenave <pwcazenave@gmail.com>2010-05-11 20:01:58 +0200
committerRobby Workman <rworkman@slackbuilds.org>2010-05-11 20:01:58 +0200
commita50a71b73c947bea8b2b1d0b32c793f4dc57ed34 (patch)
tree39640d47519e102afc7007cb52f739ee74a7fc21 /system/fish/doinst.sh
parentc3626a392f5d6116a4f998ec41f8bc8dbe125e9b (diff)
system/fish: Added to 12.0 repository
Diffstat (limited to 'system/fish/doinst.sh')
-rw-r--r--system/fish/doinst.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/system/fish/doinst.sh b/system/fish/doinst.sh
new file mode 100644
index 0000000000000..d34cf8602d15c
--- /dev/null
+++ b/system/fish/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/fish/config.fish.new
+