archivebox.cli

Submodules

Package Contents

Classes

LazySubcommands

NotProvided

Functions

wait_for_bg_threads_to_exit

Block until the specified threads exit. e.g. pass thread_names=(‘default_hook_handler’,) to wait for webhooks. Useful for waiting for signal handlers, webhooks, etc. to finish running after a mgmt command completes.

run_subcommand

Run a given ArchiveBox subcommand with the given list of args

main

Data

__package__

__command__

BUILTIN_LIST

CLI_DIR

SUBCOMMAND_MODULES

required_attrs

is_cli_module

is_valid_cli_module

CLI_SUBCOMMANDS

meta_cmds

setup_cmds

archive_cmds

fake_db

display_first

IGNORED_BG_THREADS

Omitted

OMITTED

API

archivebox.cli.__package__

‘archivebox.cli’

archivebox.cli.__command__

‘archivebox’

archivebox.cli.BUILTIN_LIST

None

archivebox.cli.CLI_DIR

None

archivebox.cli.SUBCOMMAND_MODULES

None

archivebox.cli.required_attrs

(’package’, ‘command’, ‘main’)

archivebox.cli.is_cli_module

None

archivebox.cli.is_valid_cli_module

None

class archivebox.cli.LazySubcommands

Bases: collections.abc.Mapping

keys()
values()
items()
__getitem__(key)
__iter__()
__len__()
archivebox.cli.CLI_SUBCOMMANDS

‘LazySubcommands(…)’

archivebox.cli.meta_cmds

(‘help’, ‘version’)

archivebox.cli.setup_cmds

(‘init’, ‘setup’, ‘install’)

archivebox.cli.archive_cmds

(‘add’, ‘remove’, ‘update’, ‘list’, ‘status’, ‘schedule’, ‘server’, ‘shell’, ‘manage’)

archivebox.cli.fake_db

(‘oneshot’,)

archivebox.cli.display_first

()

archivebox.cli.IGNORED_BG_THREADS

(‘MainThread’, ‘ThreadPoolExecutor’, ‘IPythonHistorySavingThread’, ‘Scheduler’)

archivebox.cli.wait_for_bg_threads_to_exit(thread_names: Iterable[str] = (), ignore_names: Iterable[str] = IGNORED_BG_THREADS, timeout: int = 60) int

Block until the specified threads exit. e.g. pass thread_names=(‘default_hook_handler’,) to wait for webhooks. Useful for waiting for signal handlers, webhooks, etc. to finish running after a mgmt command completes.

archivebox.cli.run_subcommand(subcommand: str, subcommand_args: List[str] | None = None, stdin: Optional[IO] = None, pwd: Union[pathlib.Path, str, None] = None) None

Run a given ArchiveBox subcommand with the given list of args

class archivebox.cli.NotProvided
__len__()
__bool__()
__repr__()
archivebox.cli.Omitted

None

archivebox.cli.OMITTED

‘NotProvided(…)’

archivebox.cli.main(args: List[str] | archivebox.cli.Omitted = OMITTED, stdin: IO | archivebox.cli.Omitted = OMITTED, pwd: str | None = None) None