projects
/
be.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7be507f
)
Determine plugin_path from the location of the plugin module, not from argv[0].
author
Marien Zwart
<marienz@gentoo.org>
Wed, 5 Apr 2006 15:41:21 +0000
(17:41 +0200)
committer
Marien Zwart
<marienz@gentoo.org>
Wed, 5 Apr 2006 15:41:21 +0000
(17:41 +0200)
libbe/plugin.py
patch
|
blob
|
history
diff --git
a/libbe/plugin.py
b/libbe/plugin.py
index b175733a41d1fa74143532b8b39332ff6b10a922..4016ca1ffc3e1d5aa67b36d2f0cc1d644fd9be34 100644
(file)
--- a/
libbe/plugin.py
+++ b/
libbe/plugin.py
@@
-52,9
+52,7
@@
def get_plugin(prefix, name):
return my_import(prefix + "." + name)
return None
-plugin_path = sys.path[0]
-while not os.path.isfile(os.path.join(plugin_path, "libbe/plugin.py")):
- plugin_path = os.path.realpath(os.path.dirname(plugin_path))
+plugin_path = os.path.realpath(os.path.dirname(os.path.dirname(__file__)))
if plugin_path not in sys.path:
sys.path.append(plugin_path)
def _test():