Skip to content

topmark.cli.commands.registry

topmark / cli / commands / registry

TopMark registry command group.

Provides subcommands for inspecting TopMark registry metadata:

  • topmark registry filetypes: inspect registered file types.
  • topmark registry processors: inspect registered header processors.
  • topmark registry bindings: inspect file-type-to-processor bindings.

registry_command

registry_command()

Group for registry-related subcommands.

This group performs no action itself; use one of its subcommands:

  • filetypes: inspect registered file types.
  • processors: inspect registered header processors.
  • bindings: inspect file-type-to-processor bindings.
Source code in src/topmark/cli/commands/registry.py
@click.group(
    name=CliCmd.REGISTRY,
    context_settings=GROUP_CONTEXT_SETTINGS,
    help="Inspect TopMark registry metadata.",
    epilog=(
        "\b\n"
        "Examples:\n"
        "  # Inspect registered file types\n"
        f"  topmark {CliCmd.REGISTRY} {CliCmd.REGISTRY_FILETYPES}\n"
        "  # Inspect registered header processors\n"
        f"  topmark {CliCmd.REGISTRY} {CliCmd.REGISTRY_PROCESSORS}\n"
        "  # Inspect file-type-to-processor bindings\n"
        f"  topmark {CliCmd.REGISTRY} {CliCmd.REGISTRY_BINDINGS}\n"
    ),
)
def registry_command() -> None:
    """Group for registry-related subcommands.

    This group performs no action itself; use one of its subcommands:

      * ``filetypes``: inspect registered file types.
      * ``processors``: inspect registered header processors.
      * ``bindings``: inspect file-type-to-processor bindings.
    """