diff options
author | kotfu <kotfu@kotfu.net> | 2019-11-29 22:29:47 -0700 |
---|---|---|
committer | kotfu <kotfu@kotfu.net> | 2019-11-29 22:29:47 -0700 |
commit | 309f542d5de2d357a64bcbf0a8bdb1d90918fb0f (patch) | |
tree | 2645919f16493c8f67fa1a9106086446ebd16896 /docs/migrating/next_steps.rst | |
parent | 69b108a8865ba96fd5959a3f1a8237c5e8f18732 (diff) | |
download | cmd2-git-309f542d5de2d357a64bcbf0a8bdb1d90918fb0f.tar.gz |
Minor formatting cleanups
Diffstat (limited to 'docs/migrating/next_steps.rst')
-rw-r--r-- | docs/migrating/next_steps.rst | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/docs/migrating/next_steps.rst b/docs/migrating/next_steps.rst index f43c69c9..d95473ee 100644 --- a/docs/migrating/next_steps.rst +++ b/docs/migrating/next_steps.rst @@ -15,9 +15,8 @@ For all but the simplest of commands, it's probably easier to use `argparse ``cmd2`` provides a ``@with_argparser()`` decorator which associates an ``ArgumentParser`` object with one of your commands. Using this method will: -1. Pass your command a `Namespace -<https://docs.python.org/3/library/argparse.html#argparse.Namespace>`_ -containing the arguments instead of a string of text. +1. Pass your command a `Namespace <https://docs.python.org/3/library/argparse.html#argparse.Namespace>`_ + containing the arguments instead of a string of text. 2. Properly handle quoted string input from your users. @@ -52,8 +51,8 @@ Generating Output ----------------- If your program generates output by printing directly to ``sys.stdout``, you -should consider switching to :meth:`cmd2.cmd2.Cmd.poutput`, -:meth:`cmd2.cmd2.Cmd.perror`, and :meth:`cmd2.cmd2.Cmd.pfeedback`. These +should consider switching to :meth:`~cmd2.cmd2.Cmd.poutput`, +:meth:`~cmd2.cmd2.Cmd.perror`, and :meth:`~cmd2.cmd2.Cmd.pfeedback`. These methods work with several of the built in :ref:`features/settings:Settings` to allow the user to view or suppress feedback (i.e. progress or status output). They also properly handle ansi colored output according to user preference. |