diff options
author | Ken Roberts <alisonken1@juno.com> | 2014-04-15 23:03:06 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2014-04-23 07:51:25 +0700 |
commit | 9fd36e098c94ba888812f2c9a56db1463b66025b (patch) | |
tree | 452de4e509e51b02a9a700edde401ae883e8dd05 /business/trytond/doinst.sh | |
parent | b6dd59e30fd126ed0bc90b149dcf039fdff0ec95 (diff) | |
download | slackbuilds-9fd36e098c94ba888812f2c9a56db1463b66025b.tar.gz |
business/trytond: Updated for version 3.0.4.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'business/trytond/doinst.sh')
-rw-r--r-- | business/trytond/doinst.sh | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/business/trytond/doinst.sh b/business/trytond/doinst.sh index b158529247..dc2666f510 100644 --- a/business/trytond/doinst.sh +++ b/business/trytond/doinst.sh @@ -11,12 +11,16 @@ config() { # Otherwise, we leave the .new copy for the admin to consider... } -# Keep same perms on rc.openerp-server.new: -if [ -e etc/rc.d/rc.trytond ]; then - cp -a etc/rc.d/rc.trytond etc/rc.d/rc.trytond.new.incoming - cat etc/rc.d/rc.trytond.new > etc/rc.d/rc.trytond.new.incoming - mv etc/rc.d/rc.trytond.new.incoming etc/rc.d/rc.trytond.new -fi +preserve_perms() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + if [ -e $OLD ]; then + cp -a $OLD ${NEW}.incoming + cat $NEW > ${NEW}.incoming + mv ${NEW}.incoming $NEW + fi + config $NEW +} -config etc/rc.d/rc.trytond.new -config etc/trytond/trytond.conf.new +preserve_perms etc/rc.d/rc.trytond.new +config etc/trytond.conf.new |