summaryrefslogtreecommitdiff
path: root/cmd2.py
diff options
context:
space:
mode:
Diffstat (limited to 'cmd2.py')
-rwxr-xr-xcmd2.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/cmd2.py b/cmd2.py
index 54eff811..6a2449a5 100755
--- a/cmd2.py
+++ b/cmd2.py
@@ -392,6 +392,13 @@ def write_to_paste_buffer(txt):
pyperclip.copy(txt)
+def reprint_prompt():
+ if rl_type == RlType.GNU:
+ readline_lib.rl_forced_update_display()
+ elif rl_type == RlType.PYREADLINE:
+ readline.rl.mode._print_prompt()
+
+
class ParsedString(str):
"""Subclass of str which also stores a pyparsing.ParseResults object containing structured parse results."""
# pyarsing.ParseResults - structured parse results, to provide multiple means of access to the parsed data