diff options
| author | Olivier Dony <odo@openerp.com> | 2016-09-02 13:24:09 +0200 |
|---|---|---|
| committer | Olivier Dony <odo@openerp.com> | 2016-09-05 11:57:50 +0200 |
| commit | 4339196e5231aa734a0154e2f4e88b2e54f27d48 (patch) | |
| tree | a5e140610e000ced1fccea3cf24358efc6f06883 /odoo/cli/start.py | |
| parent | c0566b289608f2ebb97ece4683440a551c8db9b9 (diff) | |
[IMP] support v10 manifest file naming convention
- As of v10, manifest files should be named `__manifest__.py`
- For backwards-compatibility, __openerp__.py manifest files
will still be supported for the time being
- Limited refactoring, to add support for the 2 different
naming conventions
- All textual references to __openerp_.py updated in
documentation and examples
Diffstat (limited to 'odoo/cli/start.py')
| -rw-r--r-- | odoo/cli/start.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/odoo/cli/start.py b/odoo/cli/start.py index 69058224117..043c411ad8d 100644 --- a/odoo/cli/start.py +++ b/odoo/cli/start.py @@ -2,12 +2,13 @@ # -*- coding: utf-8 -*- import argparse import glob +import itertools import os import sys from . import Command from .server import main -from odoo.modules.module import get_module_root, MANIFEST +from odoo.modules.module import get_module_root, MANIFEST_NAMES from odoo.service.db import _create_empty_database, DatabaseExists @@ -15,10 +16,12 @@ class Start(Command): """Quick start the Odoo server for your project""" def get_module_list(self, path): - mods = glob.glob(os.path.join(path, '*/%s' % MANIFEST)) + mods = itertools.chain.from_iterable( + glob.glob(os.path.join(path, '*/%s' % mname)) + for mname in MANIFEST_NAMES + ) return [mod.split(os.path.sep)[-2] for mod in mods] - def run(self, cmdargs): parser = argparse.ArgumentParser( prog="%s start" % sys.argv[0].split(os.path.sep)[-1], |
