Skip to content

CLI Reference

Nexus-Dev provides a comprehensive set of command-line tools for managing your knowledge base.


Available Commands

Command Description
nexus-init Initialize a new Nexus-Dev project
nexus-index Index files into the knowledge base
nexus-status Show project status and statistics
nexus-inspect Inspect database contents for debugging
nexus-clean Delete indexed data for a project
nexus-search Search the knowledge base
nexus-export Export knowledge base to markdown
nexus-reindex Re-index entire project
nexus-import-github Import GitHub issues/PRs
nexus-mcp Start MCP server
nexus-agent Run agentic tasks
nexus-agent-config Configure project agent (AGENTS.md)
nexus-index-mcp Index MCP server definitions

Quick Reference

Initialize a new project

nexus-init --project-name "my-project" --embedding-provider openai

Index code and documentation

nexus-index src/ docs/ -r

Check project status

nexus-status

Search the knowledge base

nexus-search "authentication function"

Global Options

All commands support these standard options:

Option Description
--help Show command help and exit
--version Show version and exit

Environment Variables

Commands respect these environment variables:

Variable Purpose
OPENAI_API_KEY Required for OpenAI embeddings
NEXUS_PROJECT_ROOT Override project root detection
NEXUS_DB_PATH Custom database location

Exit Codes

Code Meaning
0 Success
1 Error (missing config, invalid arguments, etc.)