diff options
author | Todd Leonhardt <todd.leonhardt@gmail.com> | 2018-11-01 21:38:07 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-01 21:38:07 -0400 |
commit | b6c39365e0331ab64aad074565fe73fb074a3a7f (patch) | |
tree | e91b10747421b4b6bb4bb794cc2d2d0543efb462 /cmd2/cmd2.py | |
parent | eaf2918a8036e95a373cd9694317335dbc548cad (diff) | |
parent | dd44ed27eb832065760935b1028d68937d74b308 (diff) | |
download | cmd2-git-b6c39365e0331ab64aad074565fe73fb074a3a7f.tar.gz |
Merge pull request #595 from ethanmcc/strip-color-when-redirecting-ppaged
Strip color codes when redirecting w/ ppaged()
Diffstat (limited to 'cmd2/cmd2.py')
-rw-r--r-- | cmd2/cmd2.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd2/cmd2.py b/cmd2/cmd2.py index 718f311f..6f9350c6 100644 --- a/cmd2/cmd2.py +++ b/cmd2/cmd2.py @@ -704,7 +704,7 @@ class Cmd(cmd.Cmd): break self.pipe_proc = None else: - self.stdout.write(msg_str) + self.decolorized_write(self.stdout, msg_str) except BrokenPipeError: # This occurs if a command's output is being piped to another process and that process closes before the # command is finished. If you would like your application to print a warning message, then set the |