Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/cocoindex_code/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,11 @@ def _format_progress(progress: IndexingProgress) -> str:
)


def print_project_header(project_root: str) -> None:
"""Print the project root directory."""
_typer.echo(f"Project: {project_root}")


def print_index_stats(status: ProjectStatusResponse) -> None:
"""Print formatted index statistics."""
if status.progress is not None:
Expand Down Expand Up @@ -261,6 +266,7 @@ def init(
def index() -> None:
"""Create/update index for the codebase."""
client, project_root = require_daemon_for_project()
print_project_header(project_root)

_run_index_with_progress(client, project_root)

Expand Down Expand Up @@ -310,6 +316,7 @@ def search(
def status() -> None:
"""Show project status."""
client, project_root = require_daemon_for_project()
print_project_header(project_root)
resp = client.project_status(project_root)
print_index_stats(resp)

Expand Down
Loading