summaryrefslogtreecommitdiff
path: root/openerpcommand
diff options
context:
space:
mode:
authorChristophe Simonis <chs@openerp.com>2013-11-14 14:55:02 +0100
committerChristophe Simonis <chs@openerp.com>2013-11-14 14:55:02 +0100
commitec88c042b29ab1e4e17bd343e2e5da829e088c83 (patch)
tree5425cf0e5f9ca5370074960b529c9edcb2724260 /openerpcommand
parent7c1cb42e1769ea32fa79468a2d7dfe0ac28fd8a9 (diff)
parent993bff902e22ab77b7a36d3f48ed12511e93e2b1 (diff)
[MERGE] forward port of branch saas-1 up to revid 4918 chs@openerp.com-20131114134731-n324awyon0spq624
bzr revid: chs@openerp.com-20131114135502-xqi6df3jzm7ng0io
Diffstat (limited to 'openerpcommand')
-rw-r--r--openerpcommand/common.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/openerpcommand/common.py b/openerpcommand/common.py
index f306d7f4b2d..9209f8e1eb6 100644
--- a/openerpcommand/common.py
+++ b/openerpcommand/common.py
@@ -40,8 +40,7 @@ def get_addons_from_paths(paths, exclude):
module_names = []
for p in paths:
if os.path.exists(p):
- names = list(set(os.listdir(p)))
- names = filter(lambda a: not (a.startswith('.') or a in exclude), names)
+ names = [n for n in os.listdir(p) if os.path.isfile(os.path.join(p, n, '__openerp__.py')) and not n.startswith('.') and n not in exclude]
names = filter(lambda a: os.path.isdir(os.path.join(p, a)), names)
names = filter(lambda a: os.path.exists(os.path.join(p, a, '__openerp__.py')), names)
module_names.extend(names)