Overview
Thelist_repos tool discovers all repositories that have been indexed by GitNexus. This is the essential first step when working with multiple repositories, providing metadata about each indexed repo including stats, commit info, and indexing status.
When to use: First step when multiple repos are indexed, or to discover available repos.Next step: READ
gitnexus://repo/{name}/context for the repo you want to work with.Parameters
This tool takes no parameters.Response
Returns an array of repository objects, each containing:Repository name (derived from path)
Absolute path to the repository on disk
ISO 8601 timestamp of when the repo was last indexed
Information about the most recent commit
Repository indexing statistics
Example Usage
Basic Usage
Example Response
Multi-Repo Workflow
When multiple repositories are indexed, you must specify therepo parameter on other tools to target the correct repository:
Best Practices
Always start with list_repos
Always start with list_repos
When working with multiple repositories, call
list_repos first to understand what’s available and ensure you’re targeting the correct repo in subsequent calls.Check indexing freshness
Check indexing freshness
Compare
indexedAt with lastCommit.date to identify stale indexes. If the index is outdated, run npx gitnexus analyze to refresh.Review stats for context
Review stats for context
Use the stats to understand repository size and complexity before diving into queries. Large symbol counts may require more focused queries.
Related Tools
- query - Search for execution flows after identifying the target repo
- context - Get detailed symbol information within a specific repo
Related Resources
gitnexus://repos- Alternative way to list repos via MCP resourcesgitnexus://repo/{name}/context- Detailed repo context including staleness warnings