[IMP] runbot: handle new binary for 10.0

This commit is contained in:
Christophe Simonis 2016-09-29 14:33:15 +02:00
parent 48e652436e
commit b04488f22f

View File

@ -869,14 +869,15 @@ class runbot_build(osv.osv):
def cmd(self, cr, uid, ids, context=None): def cmd(self, cr, uid, ids, context=None):
"""Return a list describing the command to start the build""" """Return a list describing the command to start the build"""
for build in self.browse(cr, uid, ids, context=context): for build in self.browse(cr, uid, ids, context=context):
# Server bins = [
server_path = build.path("openerp-server") 'odoo-bin', # >= 10.0
# for 7.0 'openerp-server', # 9.0, 8.0
if not os.path.isfile(server_path): 'openerp-server.py', # 7.0
server_path = build.path("openerp-server.py") 'bin/openerp-server.py', # < 7.0
# for 6.0 branches ]
if not os.path.isfile(server_path): for server_path in map(build.path, bins):
server_path = build.path("bin/openerp-server.py") if os.path.isfile(server_path):
break
# commandline # commandline
cmd = [ cmd = [