local_run: Augment existing PYTHONPATH
This commit is contained in:
parent
2fed5f676c
commit
665e19b80b
1 changed files with 4 additions and 1 deletions
|
|
@ -16,8 +16,11 @@ wd = os.path.join(project, 'localconfig')
|
|||
if not os.path.isdir(wd):
|
||||
os.makedirs(wd)
|
||||
|
||||
paths = os.getenv('PYTHONPATH', '').split(':')
|
||||
if project not in paths:
|
||||
paths.insert(0, project)
|
||||
env = os.environ.copy()
|
||||
env['PYTHONPATH'] = project
|
||||
env['PYTHONPATH'] = ':'.join(p for p in paths if p)
|
||||
env['WEBOOB_WORKDIR'] = wd
|
||||
env['WEBOOB_BACKENDS'] = os.getenv('WEBOOB_LOCAL_BACKENDS',
|
||||
os.getenv('WEBOOB_BACKENDS',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue