[FIX] oe: listing of modules only take directories having a __openerp__.py file
bzr revid: chs@openerp.com-20131031152716-sda5397b4n0be1ih
This commit is contained in:
parent
82211b1ac2
commit
ab93864dfc
|
@ -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]
|
||||
module_names.extend(names)
|
||||
else:
|
||||
print "The addons path `%s` doesn't exist." % p
|
||||
|
|
Loading…
Reference in New Issue