Skip to content

codersauce/red

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

511 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

red

CI Plugin System Check Release Latest release License: MIT Discord

The modal editor for the agent era.

Fast, familiar editing with modern code intelligence and a safer way to work with agents. One self-contained Rust binary. No required configuration. Your files stay yours.

Website · Download · Getting started · Documentation · Community

The current documented release is v0.2.4.

Red editing its Rust rendering pipeline with the project tree open

Husk language

The source tree contains the extracted Husk embedding API, standalone CLI, local package resolver, and portable WebAssembly Component extension runtime. Start with the language and embedding guide. The research and implementation plan and card-by-card status explain the dynamic Rust-crate design, completed work, and remaining release-hardening tasks.

Install

Homebrew

brew install codersauce/tap/red

macOS and Linux

curl --proto '=https' --tlsv1.2 -fsSL https://getred.dev/install.sh | sh

The installer selects the correct macOS or x86_64 glibc Linux archive, verifies its published SHA-256 checksum, installs to ~/.local/bin, and runs Red's built-in self-check.

Windows

irm https://getred.dev/install.ps1 | iex

The PowerShell installer verifies the release checksum, installs to %LOCALAPPDATA%\Programs\Red\bin, and adds that directory to your user PATH.

To pin a release or choose another directory:

RED_VERSION=0.2.4 RED_INSTALL_DIR="$HOME/bin" \
  sh -c "$(curl --proto '=https' --tlsv1.2 -fsSL https://getred.dev/install.sh)"

You can also download a prebuilt archive or build from source. Red's editor, default configuration, themes, and plugins are bundled into the executable.

Agent support is optional. It requires Codex CLI 0.144.1 or newer and a completed codex login.

Why Red

  • Stay in flow. Vim-inspired modes, motions, text objects, splits, and pickers are paired with tree-sitter highlighting and asynchronous language tools.
  • Find the signal. Jump to files, commands, symbols, definitions, references, diagnostics, or Git changes without leaving the keyboard.
  • Make it yours. Embedded Husk plugins power the file tree, project search, Git workspace, and theme browser. Defaults work immediately; configuration remains optional.
  • Keep the final say. Red gives Codex editor context, including unsaved buffers, while staging every suggested write as an isolated proposal for explicit review.
  • Work reliably. Atomic recovery works across platforms, and Unix detach/attach sessions preserve buffers, plugins, LSP state, and running agents across terminal or SSH disconnects.

First five minutes

Open a file:

red path/to/file

Red offers to create a starter config on the first interactive run. Declining is fine: the embedded defaults, plugins, and themes are enough to start editing.

Key Action
Space ? Discover commands and their effective keymaps
Ctrl-p Find a file with fuzzy search and live preview
Space G Open the Git status workspace
Space A Ask the agent with editor context
:AgentReview Review pending agent proposals
Space t Browse themes with live preview

See Getting started for editing, navigation, configuration, language servers, Git, CLI, and troubleshooting guidance. The Vim compatibility matrix is the precise, versioned behavior contract.

A safer agent workflow

Red preparing a contextual agent prompt over the active source file

Every agent edit is a proposal. Nothing touches your files until you accept it.

  1. Ask. Open the agent with Space A; Red includes a bounded selection or cursor excerpt, unsaved contents, and relevant diagnostics.
  2. Review. Codex reads editor state and stages attributed changes in an isolated proposal filesystem. Open them with :AgentReview.
  3. Decide. Accept the useful hunks and reject the rest. Codex does not silently write into the workspace.

The integration uses the Codex app-server directly and supports persistent conversation, queued follow-ups, live tool progress, and explicit session controls. Ignored, out-of-workspace, binary, and common secret files are excluded from context. Read the agent workflow and safety contract for prerequisites, limits, commands, and failure behavior.

What Red ships today

The current release includes:

  • Normal, Insert, Visual, Visual Line, Visual Block, and Command modes with expanding Vim motion and editing compatibility
  • tree-sitter highlighting for Rust, Markdown, JavaScript, TypeScript/TSX, JSON, TOML, YAML, Python, Bash, PowerShell, Lua, and Husk
  • a first-party Husk language server plus built-in LSP defaults for Rust, TypeScript/JavaScript, Python, Markdown, JSON, TOML, YAML, and Lua
  • command and keymap discovery, fuzzy files, buffer navigation, symbols, references, project search, and diagnostics
  • native Git gutter signs, hunk actions, and a full-screen workspace for staging, commits, branches, remotes, stashes, logs, and rebases
  • an embedded Husk runtime with bundled file tree, search, Git, progress, inlay-hint, symbol, theme, and agent plugins
  • a branded startup splash, the Red theme, accessible selection and cursor contrast, and optimized rendering hot paths
  • atomic crash recovery on every platform and detachable sessions on macOS and Linux

See the latest release notes or the complete changelog for details.

Configuration

Red layers your settings over embedded defaults, so a configuration file can contain only the values you want to change:

# ~/.config/red/config.toml
theme = "red.json"
scrolloff = 8

[search]
ignorecase = true
smartcase = true

[keys.normal]
"Ctrl-s" = "Save"

The commented default_config.toml documents every setting that ships with Red. Custom themes go in ~/.config/red/themes/, and custom Husk plugins go in ~/.config/red/plugins/. Run red --runtime-files to see every visible runtime asset and its source.

Plugins and themes

Bundled plugins and themes are embedded in the binary and upgrade with Red. They are parsed and typechecked against the versioned Husk host contract before activation; an incompatible plugin is quarantined without preventing editor startup.

You can disable bundled plugins, configure them in config.toml, or eject a copy for customization:

red --eject plugins/fidget.hk
red --eject themes/red.json

An ejected asset shadows the bundled copy until you delete it. See the plugin system guide, host API, and bundled plugin source for details and examples.

Sessions

On macOS and Linux:

red --detach path/to/file
red --detach=work path/to/project
red --attach work

Leave a detachable session with Ctrl-\. Read Detachable sessions and Session recovery for lifecycle, recovery, and platform details.

Documentation

Guide Covers
Getting started Editing, keymaps, LSP, Git, CLI, and troubleshooting
Husk language server Husk editor features, external crates, configuration, and safety boundaries
Vim compatibility Supported behavior and intentional differences
Agent workflow Codex prerequisites, review model, commands, and safety
Plugin system Husk lifecycle, runtime architecture, and validation
Plugin API Versioned host API for plugin authors
Detach and attach Persistent Unix sessions
Session recovery Atomic recovery and dirty-buffer restoration
Performance Measurement, budgets, and regression process
Debugging Invariant owners, logs, diagnostic commands, and tracing paths
Releasing Release preparation, publication, and verification

Status and community

Red is an early, pre-1.0 release and is evolving quickly. Bring curiosity and keep backups for critical work.

Development

Red requires a recent stable Rust toolchain and Git:

git clone https://github.com/codersauce/red.git
cd red
cargo build
cargo test --all-targets --all-features
cargo clippy --all-targets --all-features -- -D warnings

Use RED_RUNTIME=. while iterating on bundled plugins or themes without rebuilding the executable:

RED_RUNTIME=. cargo run -- path/to/file

Contributions are welcome. For major changes, open an issue before investing in an implementation. Release maintainers should follow docs/RELEASING.md.

License

Red is available under the MIT License.

Built with love for the Rust community and inspired by Vim, Neovim, and Helix.

About

📝 Vimlike Modal Text Editor in Rust

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages