ted is a modern, cross-platform command-line text editor written in Go that uses familiar Windows-style keyboard shortcuts and intuitive arrow key navigation.
ted (Terminal EDitor) is a friendly, approachable terminal text editor designed for developers who want a powerful editing experience without the learning curve of modal editors like vim. It works in any terminal on Linux, macOS, and Windows, providing a consistent experience across all platforms.
Most terminal editors fall into two categories: simple but limited (like nano) or powerful but complex (like vim/emacs). ted bridges this gap by offering:
- Familiar shortcuts - Uses the same keyboard shortcuts you already know from modern editors (Ctrl+S to save, Ctrl+C to copy, etc.)
- No modes - Start typing immediately, no need to learn insert/command modes
- Fast and lightweight - Written in Go for speed with minimal dependencies
- Cross-platform - Identical experience whether you're on Linux, macOS, or Windows
- Terminal native - Works in any terminal, no GUI required
- Cut, Copy, Paste (Ctrl+X, Ctrl+C, Ctrl+V)
- Undo/Redo (Ctrl+Z, Ctrl+Y)
- Select all (Ctrl+A)
- Delete entire line (Ctrl+Shift+K)
- Duplicate line (Ctrl+D)
- Move line up/down (Alt+Up/Down)
- Insert line above/below (Ctrl+Shift+Enter, Ctrl+Enter)
- Arrow keys for cursor movement
- Word navigation (Ctrl+Left/Right)
- Jump to line start/end (Home/End)
- Jump to document start/end (Ctrl+Home/End)
- Page Up/Down navigation
- Go to line number (Ctrl+G)
- Shift+Arrow for character selection
- Shift+Home/End for line selection
- Ctrl+Shift+Arrow for word selection
- Double-click to select word (mouse support)
- Find (Ctrl+F)
- Find next/previous (F3/Shift+F3)
- Replace (Ctrl+H)
- Replace all (Ctrl+Shift+H)
- Case-sensitive and whole word options
- Regular expression support
- Syntax highlighting for multiple languages
- Auto-indentation
- Comment/uncomment (Ctrl+/)
- Indent/unindent (Tab/Shift+Tab)
- Jump to matching bracket (Ctrl+B)
- Show whitespace toggle (Ctrl+Shift+I)
- Toggleable line numbers (Ctrl+L)
- Current line highlighting
- Status bar with mode, encoding, and position
- Info bar with file details (filename, size, type, settings)
- Word wrap toggle (Ctrl+Shift+W)
- Responsive layout that adapts to terminal size
- Open files from command line
- Save (Ctrl+S) and Save As (Ctrl+Shift+S)
- New file (Ctrl+N)
- Close file (Ctrl+W)
- Quit (Ctrl+Q)
- Unsaved changes prompt on exit
go install github.com/AndrewDonelson/ted@latestDownload pre-built binaries from the releases page for your platform.
Open a file:
ted filename.txtCreate a new file:
ted- Ctrl+N - New file
- Ctrl+O - Open file
- Ctrl+S - Save
- Ctrl+Shift+S - Save As
- Ctrl+W - Close current file
- Ctrl+Q - Quit editor
- Ctrl+Z - Undo
- Ctrl+Y - Redo
- Ctrl+X - Cut
- Ctrl+C - Copy
- Ctrl+V - Paste
- Ctrl+A - Select all
- Delete - Delete character forward
- Backspace - Delete character backward
- Ctrl+Shift+K - Delete entire line
- Ctrl+D - Duplicate current line
- Alt+Up/Down - Move line up/down
- Ctrl+Enter - Insert line below
- Ctrl+Shift+Enter - Insert line above
- Arrow Keys - Move cursor
- Home/End - Line start/end
- Ctrl+Home/End - Document start/end
- Ctrl+Left/Right - Move by word
- Page Up/Down - Move by page
- Ctrl+G - Go to line number
- Ctrl+F - Find
- F3 - Find next
- Shift+F3 - Find previous
- Ctrl+H - Replace
- Ctrl+Shift+H - Replace all
- Esc - Close find/replace dialog
- Ctrl+/ - Toggle line comment
- Tab - Indent
- Shift+Tab - Unindent
- Ctrl+B - Jump to matching bracket
- Ctrl+L - Toggle line numbers
- Ctrl+Shift+W - Toggle word wrap
- Ctrl+Shift+I - Toggle show whitespace
- F10 or Alt+Key - Activate menu bar
Access menus using Alt+Key (e.g., Alt+F for File menu) or F10 to activate the first menu. Navigate with arrow keys and press Enter to select. Press Esc to close menus.
- Tab size: 4 spaces
- Use spaces: Yes (not tabs)
- Line numbers: Off (toggle with Ctrl+L)
- Word wrap: On (toggle with Ctrl+Shift+W)
- Color scheme: Dark mode
- Encoding: UTF-8
- Line ending: Auto-detect (preserves file's original)
Future versions will support a TOML configuration file at ~/.tedrc or ~/.config/ted/config.toml for customizing:
- Color schemes and themes
- File type associations
- Syntax highlighting preferences
- Editor settings (tab size, spaces vs tabs)
- Search defaults
Note: Keyboard shortcuts are fixed and cannot be customized. This ensures a consistent experience across all machines.
ted is designed with a simple philosophy: consistency and familiarity. The keyboard shortcuts you learn on one machine work the same way everywhere. There's no configuration needed to get started, and no need to memorize complex key combinations. Just open a file and start editing.
MIT License - see LICENSE file for details.
Contributions are welcome! Please see CONTRIBUTING.md for development guidelines.
GitHub: github.com/AndrewDonelson/ted