summaryrefslogtreecommitdiff
path: root/src/buildstream/_frontend/cli.py
diff options
context:
space:
mode:
authorTom Pollard <tom.pollard@codethink.co.uk>2019-08-13 12:16:56 +0100
committerbst-marge-bot <marge-bot@buildstream.build>2019-08-19 15:21:21 +0000
commit333258441c8cce674b9efdc585fb392d60311ddf (patch)
tree6028fbee4733f17bb3682f9e52f94fcce01e86ae /src/buildstream/_frontend/cli.py
parent1abf4ab51c4227841d5d6805dfa71675604b95d0 (diff)
downloadbuildstream-333258441c8cce674b9efdc585fb392d60311ddf.tar.gz
_frontend/app.py: shell_prompt() explicit name/key instead of Element
By explicitly having the element_name & element_key as paramaters the Element instance does not need to be passed for simply generating a prompt. This is needed for working towards process separation.
Diffstat (limited to 'src/buildstream/_frontend/cli.py')
-rw-r--r--src/buildstream/_frontend/cli.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/buildstream/_frontend/cli.py b/src/buildstream/_frontend/cli.py
index 1365cede4..a77bd80e8 100644
--- a/src/buildstream/_frontend/cli.py
+++ b/src/buildstream/_frontend/cli.py
@@ -597,7 +597,10 @@ def shell(app, element, sysroot, mount, isolate, build_, cli_buildtree, pull_, c
element = elements[-1]
pull_dependencies = elements[:-1] if pull_ else None
- prompt = app.shell_prompt(element)
+ element_name = element._get_full_name()
+ element_key = element._get_display_key()
+
+ prompt = app.shell_prompt(element_name, element_key)
mounts = [
HostMount(path, host_path)
for host_path, path in mount