From 3f94017ea20e151cefc1ebf6572e9d3339236e35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 23 Oct 2008 16:07:19 +0200 Subject: [PATCH] Fix version number Add trytond requires --- __tryton__.py | 5 +++-- setup.py | 8 ++++++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/__tryton__.py b/__tryton__.py index e6060ed33f..59845dec48 100644 --- a/__tryton__.py +++ b/__tryton__.py @@ -1,7 +1,8 @@ -#This file is part of Tryton. The COPYRIGHT file at the top level of this repository contains the full copyright notices and license terms. +#This file is part of Tryton. The COPYRIGHT file at the top level of +#this repository contains the full copyright notices and license terms. { 'name': 'Account Belgium', - 'version': '0.1', + 'version': '0.0.1', 'author': 'B2CK', 'email': 'info@b2ck.com', 'website': 'http://www.tryton.org/', diff --git a/setup.py b/setup.py index 7961a1ca20..a153d9b66b 100644 --- a/setup.py +++ b/setup.py @@ -12,13 +12,17 @@ for dep in info.get('depends', []): match = re.compile( '(ir|res|workflow|webdav)((\s|$|<|>|<=|>=|==|!=).*?$)').match(dep) if match: - dep = 'trytond' + match.group(2) + continue else: dep = 'trytond_' + dep requires.append(dep) +major_version, minor_version, _ = info.get('version', '0.0.1').split('.', 2) +requires.append('trytond >= %s.%s' % (major_version, minor_version)) +requires.append('trytond < %s.%s' % (major_version, str(int(minor_version) + 1))) + setup(name='trytond_' + info['name'].lower(), - version=info.get('version', '0'), + version=info.get('version', '0.0.1'), description=info.get('description', ''), author=info.get('author', ''), author_email=info.get('email', ''),