Add scope to setting active tree to ensure that it is set at user level

This commit is contained in:
Carson Woods
2019-07-17 13:48:56 -06:00
parent 0e6e93eaac
commit 7ab6af8a3b

View File

@@ -1499,12 +1499,14 @@ def do_install(self, **kwargs):
global_root = spack.config.get('upstreams')
global_root = global_root['global']['install_tree']
global_root = spack.util.path.canonicalize_path(global_root)
spack.config.set('config:active_tree', global_root)
spack.config.set('config:active_tree', global_root,
scope='user')
elif upstream:
raise NotImplementedError
else:
spack.config.set('config:active_tree',
spack.config.get('config:install_tree'))
spack.config.get('config:install_tree'),
scope='user')
# For external packages the workflow is simplified, and basically
# consists in module file generation and registration in the DB