Mercurial > hg > mercurial-crew-with-dirclash
changeset 4578:b1716a8b32d3
extensions: fix load of module/__init__.py on OS X
author | Brendan Cully <brendan@kublai.com> |
---|---|
date | Wed, 13 Jun 2007 19:05:20 -0700 |
parents | 78c50632437e |
children | 4500fbe3a432 |
files | mercurial/extensions.py |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/extensions.py +++ b/mercurial/extensions.py @@ -31,7 +31,8 @@ def load(ui, name, path): module_name = "hgext_%s" % name.replace('.', '_') if os.path.isdir(path): # module/__init__.py style - fd, fpath, desc = imp.find_module('', [path]) + d, f = os.path.split(path) + fd, fpath, desc = imp.find_module(f, [d]) mod = imp.load_module(module_name, fd, fpath, desc) else: mod = imp.load_source(module_name, path)