diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-06-26 02:33:18 -0400 |
---|---|---|
committer | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-06-26 02:33:18 -0400 |
commit | e34bba44ef53228aeba613ac6e928b2c315111cf (patch) | |
tree | a39a736c3a36426fe6c278105ce9f6ec5696d16c /examples | |
parent | e6f65e607c6ad2350dfce05f3d5080d0ffbe35f1 (diff) | |
download | cmd2-git-e34bba44ef53228aeba613ac6e928b2c315111cf.tar.gz |
Moved code related to ANSI escape codes to new file called ansi.py
Diffstat (limited to 'examples')
-rwxr-xr-x | examples/pirate.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/pirate.py b/examples/pirate.py index 41d7d3f4..0d9d89bc 100755 --- a/examples/pirate.py +++ b/examples/pirate.py @@ -9,7 +9,6 @@ It demonstrates many features of cmd2. import argparse import cmd2 -from cmd2 import utils from cmd2.constants import MULTILINE_TERMINATOR @@ -70,7 +69,7 @@ class Pirate(cmd2.Cmd): def do_sing(self, arg): """Sing a colorful song.""" - self.poutput(utils.style(arg, fg=self.songcolor)) + self.poutput(cmd2.ansi.style(arg, fg=self.songcolor)) yo_parser = argparse.ArgumentParser() yo_parser.add_argument('--ho', type=int, default=2, help="How often to chant 'ho'") |