def METHOD_NAME(ctx, cli_obj, default, list_, config, preview, edit, clone, delete):
    """Manage osxphotos color themes."""
    subcommands = [default, list_, config, preview, edit, clone, delete]
    subcommand_names = (
        "--default, --list, --config, --preview, --edit, --clone, --delete"
    )
    if not any(subcommands):
        click.echo(
            f"Must specify exactly one of: {subcommand_names}\n",
            err=True,
        )
        rich_click_echo(get_help_msg(METHOD_NAME), err=True)
        return
    if sum(bool(cmd) for cmd in subcommands) != 1:
        # only a single subcommand may be specified
        raise click.ClickException(f"Must specify exactly one of: {subcommand_names}")
    theme_manager = get_theme_manager()
    console = Console(METHOD_NAME=get_default_theme())
    if default:
        default = get_default_theme()
        theme_manager.list_themes(theme_names=[default.name])
        return
    if list_:
        theme_manager.list_themes()
        return
    if config:
        if config == "_DEFAULT_":
            print(get_default_theme().config)
        else:
            print(get_theme(config).config)
        return
    if preview:
        theme_ = get_default_theme() if preview == "_DEFAULT_" else get_theme(preview)
        theme_manager.preview_theme(theme_)
        return
    if edit:
        theme_ = get_default_theme() if edit == "_DEFAULT_" else get_theme(edit)
        config_file = pathlib.Path(theme_.path)
        console.print(f"Opening [filepath]{config_file}[/] in $EDITOR")
        click.edit(filename=str(config_file))
        return
    if clone:
        src_theme = get_theme(clone[0])
        dest_path = get_theme_dir() / f"{clone[1]}.theme"
        if dest_path.exists():
            raise click.ClickException(
                f"Theme '{clone[1]}' already exists at {dest_path}"
            )
        dest_theme = Theme(
            name=clone[1],
            description=src_theme.description,
            inherit=src_theme.inherit,
            tags=src_theme.tags,
            styles={
                style_name: src_theme.styles[style_name]
                for style_name in src_theme.style_names
            },
        )
        theme_manager = get_theme_manager()
        theme_manager.add(dest_theme)
        theme_ = get_theme(dest_theme.name)
        console.print(
            f"Cloned theme '[filename]{clone[0]}[/]' to '[filename]{clone[1]}[/]' "
            f"at [filepath]{theme_.path}[/]"
        )
        return
    if delete:
        theme_ = get_theme(delete)
        click.confirm(f"Are you sure you want to delete theme {delete}?", abort=True)
        theme_manager.remove(theme_)
        console.print(f"Deleted theme [filepath]{theme_.path}[/]")
        return