diff options
author | Erik Hanson <erik@slackbuilds.org> | 2011-12-10 16:27:36 -0200 |
---|---|---|
committer | Niels Horn <niels.horn@slackbuilds.org> | 2011-12-10 16:27:36 -0200 |
commit | d32a12b3d03e88cf60733aaf3e3d4ca77d79ce28 (patch) | |
tree | 77a7e7283af256e4b54fccdabf35426464714dda /development/highlight/doinst.sh | |
parent | ba539b5717e103bd8176675fdd402c067872089c (diff) | |
download | slackbuilds-d32a12b3d03e88cf60733aaf3e3d4ca77d79ce28.tar.gz |
development/highlight: Added (a universal syntax highlighter)
Signed-off-by: Niels Horn <niels.horn@slackbuilds.org>
Diffstat (limited to 'development/highlight/doinst.sh')
-rw-r--r-- | development/highlight/doinst.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/development/highlight/doinst.sh b/development/highlight/doinst.sh new file mode 100644 index 0000000000..686b2a1f0a --- /dev/null +++ b/development/highlight/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/highlight/filetypes.conf.new |