Skip to content

Commit 5446411

Browse files
committed
Added comment
1 parent 27d5785 commit 5446411

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cmd2/history.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ def pr(self, script=False, expanded=False, verbose=False) -> str:
5555

5656
# In non-verbose mode, display raw multiline commands on 1 line
5757
if self.statement.multiline_command:
58+
# This is an approximation and not meant to be a perfect piecing together of lines.
59+
# All newlines will be converted to spaces, including the ones in quoted strings that
60+
# are considered literals. Also if the final line starts with a terminator, then the
61+
# terminator will have an extra space before it in the 1 line version.
5862
ret_str = ret_str.replace('\n', ' ')
5963

6064
# Display a numbered list if not writing to a script

0 commit comments

Comments
 (0)