Commit 7e773f1d authored by Nicolas Wavrant's avatar Nicolas Wavrant

FIXUP

parent 8053d0af
......@@ -535,6 +535,22 @@ class Buildout(DictMixin):
self._setup_directories()
options = self['buildout']
link = options.get('link', "")
shared_path = shared_stack_path(link)
if link and shared_path:
shared_item_set = set(os.listdir(shared_path))
current_item_set = set(os.listdir('.'))
for name in ('bin', 'parts', 'eggs', 'develop-eggs'):
for item in os.listdir(os.path.join(shared_path, name)):
new_item_path = os.path.join(name, item)
if not os.path.exists(new_item_path) and item != 'buildout':
os.symlink(os.path.join(shared_path, name, item), new_item_path)
for item in shared_item_set - current_item_set:
os.symlink(os.path.join(shared_path, item), item)
elif link:
options['extends'] = link
# Now copy buildout and setuptools eggs, and record destination eggs:
entries = []
options = self['buildout']
......@@ -633,6 +649,12 @@ class Buildout(DictMixin):
self.install(())
def install(self, install_args):
options = self['buildout']
link = options.get('link', "")
if link and shared_path:
self._save_installed_options()
return
try:
self._install_parts(install_args)
finally:
......@@ -1799,16 +1821,17 @@ def _open(base, filename, seen, dl_options, override, downloaded):
os.remove(downloaded_filename)
options = result.get('buildout', {})
link = options.pop('link', "")
shared_path = shared_stack_path(link)
if link and shared_path:
shared_item_set = set(os.listdir(shared_path))
current_item_set = set(os.listdir('.'))
for item in shared_item_set - current_item_set:
os.symlink(os.path.join(shared_path, item), item)
Buildout.install = lambda *args : None
elif link:
options['extends'] = link
# link = options.get('link', "")
# shared_path = shared_stack_path(link)
# if link and shared_path:
# shared_item_set = set(os.listdir(shared_path))
# current_item_set = set(os.listdir('.'))
# for item in shared_item_set - current_item_set:
# if item not in ('bin', 'develop-eggs', 'eggs',):
# os.symlink(os.path.join(shared_path, item), item)
# Buildout.install = lambda *args : None
# elif link:
# options['extends'] = link
extends = options.pop('extends', None)
if 'extended-by' in options:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment