Editor
Many files, edited as one document.
Find in Files opens every match, with the lines around it, in one document made of the files themselves: type in it and the files change. There is no list of results to click through.
Multi-file documents
- Sources
- Find in Files, a project's diagnostics, the references to a symbol, and the uncommitted changes in the Git client.
- Excerpts
- Each match shows with three lines of context, file after file. An excerpt is the file's own text: two excerpts of one file stay in step.
- Cursors
- One set across all the files. Select Next Occurrence and Select All Matches cross from file to file.
- Undo
- An edit that touched many files is one step. So is Replace All across a project.
- Save
- One save writes every file that changed.
Scale
- Text
- Held as a B-tree of pieces over an append-only buffer, so an edit costs the same at the start of a file as at its end.
- Large files
- A file up to half the machine's memory opens and takes edits anywhere. On an M1 Pro, 4.3 GB opens in 6 s and a keystroke in it costs 2 ms; 8.6 GB, 68.6 million lines, opens in 52 s. The window waits while a file this size loads.
- Cursors
- No cap. With a million cursors a frame takes 0.3 ms to draw, against 0.25 ms with one, and a character typed at all of them takes 0.5 s.
- Regex
- Shell's own engine: a lazily built DFA finds the match, a memoizing matcher fills in the captures. A pattern without back-references runs in time linear in the text.
Undo
- Branching
- Editing after an undo keeps the undone steps as a branch, and every state stays reachable.
- Persistence
- History is written as you type and restored after a restart, for saved files too.
- Unsaved files
- Come back as you left them, named or not.
Languages
- Highlighting
- 72 languages, from Sublime Text grammars read by Shell's own engine.
- Language servers
- clangd, rust-analyzer, gopls, pyright, typescript-language-server, zls, lua-language-server and others you add: completion, diagnostics, hover, go to definition, references, rename, formatting, code actions, inlay hints.
- C without a server
- For C, though not C++, Shell's own compiler checks open files, and answers go to definition, hover and references.
- Symbols
- Go to a symbol in the file or the project, from the same search that finds files and actions.
Editing
- Vim mode
- Motions, text objects, visual block, registers, macros, marks, and an Ex line with
:s,:gand:sort. - Keymaps
- Presets from VS Code, JetBrains, Sublime Text, Emacs and Xcode. Every shortcut can be rebound.
- Also
- Folding, bracket matching, indent guides, a minimap, soft wrap, sticky scroll, rulers.
Other views of a file
- Tables
- CSV and TSV open as a table over the file's own text, with typed columns to sort and filter.
- Formatted
- Markdown, reStructuredText and AsciiDoc.
- Hex
- Any file, with the same undo.
- Compressed
.gz,.zstand.xztext files are edited in place and compressed again on save.- Remote
- Files on an SSH host open over your own
ssh, with nothing installed there. - Diff and merge
- Compare any two files, or merge three.
Limits
- A file is loaded into memory, not mapped. The largest file that can be opened is half the size of the machine's memory.
- Text is read as UTF-8 or UTF-16. Older code pages are not converted.
- The standalone diff and merge views are read-only. The uncommitted changes in the Git client are editable.
The editor is a tab beside the terminal and the Git client, in the same window.
Download Shell
Free to evaluate, with every feature and no time limit.