summaryrefslogtreecommitdiff
path: root/cmd2/parsing.py
diff options
context:
space:
mode:
authorTodd Leonhardt <todd.leonhardt@gmail.com>2019-03-03 15:53:18 -0500
committerTodd Leonhardt <todd.leonhardt@gmail.com>2019-03-03 15:53:18 -0500
commit73496248ba76cc58512142be3973a214ae9336f8 (patch)
tree4d4ba0f5bfd19b8dea8862265499ac6d072f11a3 /cmd2/parsing.py
parent009cb87895c2e23521f2fe1b69252231fa010a5a (diff)
downloadcmd2-git-73496248ba76cc58512142be3973a214ae9336f8.tar.gz
Fixed a couple bugs and added unit tests
Diffstat (limited to 'cmd2/parsing.py')
-rw-r--r--cmd2/parsing.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/cmd2/parsing.py b/cmd2/parsing.py
index 90484d76..2f22b607 100644
--- a/cmd2/parsing.py
+++ b/cmd2/parsing.py
@@ -193,12 +193,14 @@ class Statement(str):
rtn = self.command_and_args
if self.multiline_command:
rtn += constants.MULTILINE_TERMINATOR
+ elif self.terminator:
+ rtn += self.terminator
if self.suffix:
rtn += ' ' + self.suffix
if self.pipe_to:
- rtn += ' | ' + self.pipe_to
+ rtn += ' | ' + ' '.join(self.pipe_to)
if self.output:
rtn += ' ' + self.output