diff options
author | Martin Lefebvre <dadexter@gmail.com> | 2010-05-11 15:01:36 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2010-05-11 15:01:36 +0200 |
commit | 85b5e6b5712c36aaa65b0f4f669c32386704bf3e (patch) | |
tree | 96ac55d0f220842b5a936d042d1bf75ed51f5cd9 /network/surfraw/doinst.sh | |
parent | 950dbcc826ae0cf24cca4dff16f23614b790b90b (diff) |
network/surfraw: Initial import
Diffstat (limited to 'network/surfraw/doinst.sh')
-rw-r--r-- | network/surfraw/doinst.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/network/surfraw/doinst.sh b/network/surfraw/doinst.sh new file mode 100644 index 0000000000000..28a8207c28e6c --- /dev/null +++ b/network/surfraw/doinst.sh @@ -0,0 +1,17 @@ + +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/surfraw.conf.new +config etc/surfraw_elvi.list.new + |