Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Typo improvement for using CLI #372

Merged
merged 2 commits into from
Dec 9, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/using-cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ If your command corresponds to a list or tuple, you can extend your command by
adding the index of an element of the component to your command as an argument.

For example, `widget function-that-returns-list 2` will correspond to item 2 of
the result of function_that_returns_list.
the result of `function_that_returns_list`.


### Calling a function
Expand Down Expand Up @@ -90,7 +90,7 @@ See also the section on [Changing the Separator](#separator-flag).
### Instantiating a class

If your command corresponds to a class, you can extend your command by adding
the arguments of the class's \_\_init\_\_ function. Arguments must be specified
the arguments of the class's `__init__` function. Arguments must be specified
by name, using the flags syntax. See the section on
[calling a function](#calling-a-function) for more details.

Expand All @@ -105,8 +105,8 @@ after the final standalone `--` argument. (If there is no `--` argument, then no
arguments are used for flags.)

For example, to set the alsologtostderr flag, you could run the command:
`widget bang --noise=boom -- --alsologtostderr`. The --noise argument is
consumed by Fire, but the --alsologtostderr argument is treated as a normal
`widget bang --noise=boom -- --alsologtostderr`. The `--noise` argument is
consumed by Fire, but the `--alsologtostderr` argument is treated as a normal
Flag.

All CLIs built with Python Fire share some flags, as described in the next
Expand Down Expand Up @@ -143,7 +143,7 @@ interactively using Python.
Call `widget -- --completion` to generate a completion script for the Fire CLI
`widget`. To save the completion script to your home directory, you could e.g.
run `widget -- --completion > ~/.widget-completion`. You should then source this
file; to get permanent completion, source this file from your .bashrc file.
file; to get permanent completion, source this file from your `.bashrc` file.

Call `widget -- --completion fish` to generate a completion script for the Fish
shell. Source this file from your fish.config.
Expand Down Expand Up @@ -174,7 +174,7 @@ corresponds to, as well as usage information for how to extend that command.
### `--trace`: Getting a Fire trace <a name="trace-flag"></a>

In order to understand what is happening when you call Python Fire, it can be
useful to request a trace. This is done via the --trace flag, e.g.
useful to request a trace. This is done via the `--trace` flag, e.g.
`widget whack 5 -- --trace`.

A trace provides step by step information about how the Fire command was
Expand Down