(settings: BaseSettings, inproject: bool)
| 107 | |
| 108 | |
| 109 | def _print_commands(settings: BaseSettings, inproject: bool) -> None: |
| 110 | _print_header(settings, inproject) |
| 111 | print( |
| 112 | "Usage:\n", |
| 113 | " scrapy <command> [options] [args]\n", |
| 114 | "Available commands:\n", |
| 115 | ) |
| 116 | cmds = _get_commands_dict(settings, inproject) |
| 117 | print( |
| 118 | "\n".join( |
| 119 | f" {cmdname:<13} {cmdclass.short_desc()}" |
| 120 | for cmdname, cmdclass in sorted(cmds.items()) |
| 121 | ) |
| 122 | ) |
| 123 | if not inproject: |
| 124 | print( |
| 125 | "\n", |
| 126 | " [ more ] More commands available when run from project directory", |
| 127 | ) |
| 128 | print("\n", 'Use "scrapy <command> -h" to see more info about a command') |
| 129 | |
| 130 | |
| 131 | def _print_unknown_command_msg( |
no test coverage detected