Skip to content
Myr

Merge pull request #2870 from jerr0328/docs-update-cli-scriptinfo

Before adoption: this commit came in with the history the project adopted, so no landing records it.

📚 Improve docs about ScriptInfo

authored by David Lord · committed by GitHub · parents 06b189b, c7791bb · Browse files · 1 file+6 added−4 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+6 added−4 removed

  • other:+6 added−4 removed

1 file+6 added−4 removed

modified:docs/cli.rst+6 added-4 removed
76 unmodified lines
77found, the command looks for a factory function named ``create_app`` or78``make_app`` that returns an instance.7980When calling an application factory, if the factory takes an argument named81``info``, then the :class:`~cli.ScriptInfo` instance is passed as a keyword82argument. If parentheses follow the factory name, their contents are parsed83as Python literals and passes as arguments to the function. This means that84strings must still be in quotes.81``script_info``, then the :class:`~cli.ScriptInfo` instance is passed as a82keyword argument. If the application factory takes only one argument and no83parentheses follow the factory name, the :class:`~cli.ScriptInfo` instance84is passed as a positional argument. If parentheses follow the factory name,85their contents are parsed as Python literals and passes as arguments to the86function. This means that strings must still be in quotes.878889Run the Development Server90--------------------------
378 unmodified lines