Crush is an agentic AI coding assistant designed for developers who want to interact with LLMs directly in their terminal, combining the power of large language models with their existing tooling. It bridges the gap between AI capabilities and real-world development workflows by integrating with LSPs, MCPs, and version control systems to provide context-aware code suggestions, edits, and automation.
Built on the Charm ecosystem, Crush supports multiple LLM providers including OpenAI, Anthropic, Groq, and Amazon Bedrock via API keys or environment variables. It runs natively across macOS, Linux, Windows (PowerShell/WSL), FreeBSD, OpenBSD, and NetBSD, and extends functionality through Model Context Protocol (MCP) servers and Language Server Protocol (LSP) integrations. Deployment is flexible—installable via package managers, Go, or Nix, with full configuration support via JSON files and environment variables.
What You Get
- Multi-Model Support - Switch between OpenAI, Anthropic, Groq, Vercel AI Gateway, Google Gemini, Hugging Face, Amazon Bedrock, Azure OpenAI, and more—all within the same session using API keys or environment variables.
- Session-Based Context - Maintain multiple independent coding sessions per project, preserving context across interactions without losing state or requiring manual reconfiguration.
- LSP-Enhanced Context - Integrate with language servers like gopls, typescript-language-server, and nil to provide real-time code structure, diagnostics, and symbol resolution to the LLM for accurate suggestions.
- Model Context Protocol (MCP) Integration - Extend Crush with custom tools via HTTP, stdio, or SSE endpoints; supports environment variable expansion (e.g., ”$(echo $GH_PAT)”) for secure API access to GitHub, custom services, or internal tools.
- .crushignore Support - Exclude files from AI context using a .gitignore-compatible syntax, allowing fine-grained control over what code files the AI can access during sessions.
- Permission-Based Tool Execution - Control which tools (ls, grep, edit, etc.) can run automatically without user confirmation, enabling automation while maintaining security through configurable allowlists.
- Cross-Platform Terminal Native - First-class support on macOS, Linux, Windows (PowerShell/WSL), Android, FreeBSD, OpenBSD, and NetBSD—no browser or GUI required, fully CLI-first.
- Built-in Config Assistant - Use the
crush-config skill to configure Crush interactively via natural language prompts, reducing manual JSON editing.
Common Use Cases
- Refactoring legacy codebases - A senior engineer uses Crush to analyze large Go modules with gopls context, then asks it to rewrite deprecated patterns while preserving API contracts.
- Rapid prototyping with custom APIs - A startup developer connects Crush to an internal MCP server exposing their microservice docs and test suite, enabling AI-generated API clients directly from terminal prompts.
- Maintaining multi-language projects - A full-stack developer switches between TypeScript (via typescript-language-server) and Nix (via nil) contexts mid-session to fix frontend and infrastructure bugs in one workflow.
- Secure AI-assisted DevOps - A DevOps engineer configures Crush with GitHub MCP and AWS Bedrock to auto-generate Terraform modules and IAM policies using environment variables for secrets, without exposing keys in logs.
Under The Hood
Architecture
- Clean separation of concerns with a CLI command pattern that isolates application bootstrap from business logic
- Strongly typed configuration via JSON Schema with nested references, enabling schema-driven validation and IDE support
- Type-safe database access using SQLC-generated queries from SQL files, ensuring compile-time correctness
- Plugin-like LSP and MCP configurations with filetype and root_marker semantics, supporting extensible tooling integration
- Implicit dependency injection through package-level initialization and well-defined module boundaries
- Tooling pipeline tightly integrated into build and test workflows, making code quality and schema consistency non-negotiable
Tech Stack
- Go 1.25+ backend with CGO disabled and performance optimizations enabled
- SQLite with SQLC for type-safe data access, driven by migration-first development
- Comprehensive static analysis via golangci-lint with specialized checkers for SQL, context, and code health
- Taskfile-based build system unifying testing, formatting, profiling, and release automation
- Goreleaser for cross-platform binary distribution with automated documentation generation
- JSON Schema and LSP/MCP configurations defining AI tooling integrations as first-class entities
Code Quality
- Extensive test coverage spanning unit, integration, and edge cases with testify for robust assertions
- Modular components with clear interfaces and dependency injection, enabling testability and isolation
- Strong type safety and explicit error handling throughout, with no panics and comprehensive error propagation
- Consistent, idiomatic Go naming and structure across packages and tests
- Advanced tooling like VCR for deterministic external interaction testing, goleak for goroutine hygiene, and synctest for reproducible behavior
- Rigorous linting and validation pipelines enforcing standards at every stage of development
What Makes It Unique
- Native Unix socket and Windows named pipe communication for low-latency, process-local AI interactions
- Integrated LSP and MCP protocols embedded directly into the CLI, eliminating need for external servers
- Agent-based architecture with dynamic plugin loading that adapts to project context and user behavior
- Workspace-aware session persistence that retains context across terminal sessions using structured metadata
- Terminal-first UI design preserving native workflows while embedding intelligent AI assistance
- Seamless integration with Charm’s ecosystem to deliver a visually rich, cohesive terminal AI experience