[FIX] odoo.py git_locate
This commit is contained in:
parent
2f4984b838
commit
1f7a2eaf30
8
odoo.py
8
odoo.py
|
@ -50,11 +50,9 @@ def git_locate():
|
||||||
while path != '/':
|
while path != '/':
|
||||||
gitconfig_path = os.path.join(path, '.git/config')
|
gitconfig_path = os.path.join(path, '.git/config')
|
||||||
if os.path.isfile(gitconfig_path):
|
if os.path.isfile(gitconfig_path):
|
||||||
setup_py = os.path.join(path, 'setup.py')
|
release_py = os.path.join(path, 'openerp/release.py')
|
||||||
if os.path.isfile(setup_py):
|
if os.path.isfile(release_py):
|
||||||
content = open(setup_py).read()
|
break
|
||||||
if content.find('release.py') != -1:
|
|
||||||
break
|
|
||||||
path = os.path.dirname(path)
|
path = os.path.dirname(path)
|
||||||
if path == '/':
|
if path == '/':
|
||||||
path = None
|
path = None
|
||||||
|
|
Loading…
Reference in New Issue