summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJürg Billeter <j@bitron.ch>2020-10-06 08:01:42 +0200
committerJürg Billeter <j@bitron.ch>2020-10-07 14:26:38 +0200
commit36802e5198f3bb093324387860237c8e4ca4cab9 (patch)
treedef75b412e9a2fad4641cc9295506d6de38f6180
parent7ada4005c99fbbe6acbceb22c2968ba469c9e17b (diff)
downloadbuildstream-36802e5198f3bb093324387860237c8e4ca4cab9.tar.gz
_frontend/cli.py: Make bst shell --use-buildtree imply --build
-rw-r--r--src/buildstream/_frontend/cli.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/buildstream/_frontend/cli.py b/src/buildstream/_frontend/cli.py
index 9b8150cca..24ac6912e 100644
--- a/src/buildstream/_frontend/cli.py
+++ b/src/buildstream/_frontend/cli.py
@@ -617,6 +617,10 @@ def shell(app, element, mount, isolate, build_, cli_buildtree, pull_, command):
from ..element import _Scope
from .._project import HostMount
+ # Buildtree can only be used with build shells
+ if cli_buildtree != "never":
+ build_ = True
+
scope = _Scope.BUILD if build_ else _Scope.RUN
# We may need to fetch dependency artifacts if we're pulling the artifact