diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/cmd/view.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/lib/spack/spack/cmd/view.py b/lib/spack/spack/cmd/view.py index b847e89240..153168cf71 100644 --- a/lib/spack/spack/cmd/view.py +++ b/lib/spack/spack/cmd/view.py @@ -55,12 +55,12 @@ YamlFilesystemView. import os import llnl.util.tty as tty +from llnl.util.link_tree import MergeConflictError import spack.cmd import spack.store from spack.filesystem_view import YamlFilesystemView - description = "produce a single-rooted directory view of packages" section = "environment" level = "short" @@ -208,9 +208,15 @@ def view(parser, args): # Map action to corresponding functionality if args.action in actions_link: - view.add_specs(*specs, - with_dependencies=with_dependencies, - exclude=args.exclude) + try: + view.add_specs(*specs, + with_dependencies=with_dependencies, + exclude=args.exclude) + except MergeConflictError: + tty.info("Some file blocked the merge, adding the '-i' flag will " + "ignore this conflict. For more information see e.g. " + "https://github.com/spack/spack/issues/9029") + raise elif args.action in actions_remove: view.remove_specs(*specs, |