Skip to content

Commit b45fec9

Browse files
committed
Minor spelling and grammar fixes
1 parent efadff3 commit b45fec9

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

docs/features/commands.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -112,15 +112,15 @@ terminator
112112
For many simple commands, like the ``echo`` command above, you can ignore the
113113
``Statement`` object and all of it's attributes and just use the passed value
114114
as a string. You might choose to use the ``argv`` attribute to do more
115-
sophisticated argument processing. Before you go to far down that path, you
115+
sophisticated argument processing. Before you go too far down that path, you
116116
should check out the :ref:`features/argument_processing:Argument Processing`
117117
functionality included with ``cmd2``.
118118

119119

120120
Return Values
121121
-------------
122122

123-
Most commands should return nothing (either my omitting a ``return`` statement,
123+
Most commands should return nothing (either by omitting a ``return`` statement,
124124
or by ``return None``. This indicates that your command is finished (with or
125125
without errors), and that ``cmd2`` should prompt the user for more input.
126126

@@ -142,7 +142,7 @@ The ``cmd2.Cmd`` object sets an ``exit_code`` attribute to zero when it is
142142
instantiated. The value of this attribute is returned from the ``cmdloop()``
143143
call. Therefore, if you don't do anything with this attribute in your code,
144144
``cmdloop()`` will (almost) always return zero. There are a few built-in
145-
``cmd2`` commands which set ``exit_code`` to ``-1`` if an error occers.
145+
``cmd2`` commands which set ``exit_code`` to ``-1`` if an error occurs.
146146

147147
You can use this capability to easily return your own values to the operating
148148
system shell::
@@ -157,7 +157,7 @@ system shell::
157157

158158
def do_bail(self, line):
159159
"""Exit the application""
160-
self.poutput("fatal error, exiting")
160+
self.perror("fatal error, exiting")
161161
self.exit_code = 2
162162
return true
163163

@@ -178,7 +178,7 @@ the following interaction::
178178
Exception Handling
179179
------------------
180180

181-
You may choose you may choose to catch and handle any exceptions which occur in
181+
You may choose to catch and handle any exceptions which occur in
182182
a command method. If the command method raises an exception, ``cmd2`` will
183183
catch it and display it for you. The `debug` :ref:`setting
184184
<features/settings:Settings>` controls how the exception is displayed. If
@@ -193,6 +193,6 @@ Disabling or Hiding Commands
193193
See :ref:`features/disable_commands:Disabling Commands` for details of how
194194
to:
195195

196-
- removing commands included in ``cmd2``
197-
- hiding commands from the help menu
198-
- disabling and re-enabling commands at runtime
196+
- remove commands included in ``cmd2``
197+
- hide commands from the help menu
198+
- disable and re-enable commands at runtime

docs/features/disable_commands.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Disabling Commands
44
``cmd2`` allows a developer to:
55

66
- remove commands included in ``cmd2``
7-
- prevent commands from appearing in the help menu (hiding commands)
7+
- prevent commands from appearing in the help menu (hide commands)
88
- disable and re-enable commands at runtime
99

1010

0 commit comments

Comments
 (0)