"""Git remote URL construction for paude sessions."""

# Re-export subprocess so existing test patches against
# "paude.git_remote.subprocess.run" continue to work.
import subprocess as subprocess  # noqa: F811, PLC0414

from paude.git_remote.container_ops import (
    _SET_BASE_REF_CMD,
    _build_clone_from_origin_cmd,
    _build_set_origin_cmd,
    _build_workspace_init_cmd,
    _exec_in_container,
    _run_cmd,
    clone_from_origin,
    initialize_container_workspace,
    set_base_ref_in_container,
    set_origin_in_container,
    setup_precommit_in_container,
)
from paude.git_remote.exec_cmd import (
    ExecCmdBuilder,
    openshift_exec_builder,
    podman_exec_builder,
)
from paude.git_remote.utils import (
    build_openshift_remote_url,
    build_podman_remote_url,
    build_ssh_remote_url,
    count_local_only_commits,
    enable_ext_protocol,
    get_branch_remote_url,
    get_current_branch,
    get_upstream_url,
    git_diff_stat,
    git_fetch_from_remote,
    git_push_tags_to_remote,
    git_push_to_remote,
    git_remote_add,
    git_remote_remove,
    is_container_running_podman,
    is_ext_protocol_allowed,
    is_git_repository,
    is_pod_running_openshift,
    list_paude_remotes,
    resolve_origin_cmd,
    ssh_url_to_https,
)

__all__ = [
    "ExecCmdBuilder",
    "_SET_BASE_REF_CMD",
    "_build_clone_from_origin_cmd",
    "_build_set_origin_cmd",
    "_build_workspace_init_cmd",
    "_exec_in_container",
    "_run_cmd",
    "build_openshift_remote_url",
    "build_podman_remote_url",
    "build_ssh_remote_url",
    "clone_from_origin",
    "count_local_only_commits",
    "enable_ext_protocol",
    "get_branch_remote_url",
    "get_current_branch",
    "get_upstream_url",
    "git_diff_stat",
    "git_fetch_from_remote",
    "git_push_tags_to_remote",
    "git_push_to_remote",
    "git_remote_add",
    "git_remote_remove",
    "initialize_container_workspace",
    "is_container_running_podman",
    "is_ext_protocol_allowed",
    "is_git_repository",
    "is_pod_running_openshift",
    "list_paude_remotes",
    "openshift_exec_builder",
    "podman_exec_builder",
    "resolve_origin_cmd",
    "set_base_ref_in_container",
    "set_origin_in_container",
    "setup_precommit_in_container",
    "ssh_url_to_https",
]
