Textual Code
Code editor for who don't know how to use vi
What is Textual Code?
Textual Code is a TUI-based code editor that feels familiar right from the start.
You’ve probably had to SSH into a server at some point just to tweak a few lines of code. However, vi or Emacs can be overkill for quick fixes, requiring you to remember a whole host of commands for even the simplest changes. Furthermore, nano doesn’t always provide enough features for comfortable coding, and setting up a GUI editor on a remote server can be a real hassle.
That’s why Textual Code was created. You likely use a GUI editor like VS Code or Sublime Text in your day-to-day work, and Textual Code offers a similar experience with no learning curve. It behaves much like any other code editor you’re used to.
We’re not asking you to switch to Textual Code as your main editor. Just remember it’s there when you need to jump onto a server and make a few quick edits. It’s that simple.
Features
- Commonly used shortcuts, such as
Ctrl+Sto save andCtrl+Fto search - Command palette for quick access to all features, and no need to remember shortcuts
- Multiple cursors
- Mouse support
- Find and replace from workspace
- Explore files in the sidebar
- Open files to tabs
- Syntax highlighting
- Image file preview in the terminal
Installation
# Using pip
pip install textual-code
# Using uv (recommended)
uv tool install textual-code
# Run without installing
uvx textual-code
Usage
To open the textual code, run the following command in your workspace:
textual-code
Troubleshooting
Keyboard shortcuts not working
Some terminal emulators intercept certain key combinations before they reach the application. If a shortcut does not work as expected, run the following command and press the shortcut to verify that your terminal recognizes it:
# Using pip
pip install textual-dev
textual keys
# Run without installing (recommended)
uvx --from textual-dev textual keys
Development
(You need to use devcontainer to run the code)
To run the development version directly:
uv run textual-code
To run with the Textual dev console (shows logs and events), open two terminals:
# Terminal 1: start the console
uv run textual console
# Terminal 2: run the app in dev mode
uv run textual run --dev textual_code:main
Installing Hooks
Install pre-commit hooks to automatically run linting, formatting, type checking, and language checks before each commit:
uv run pre-commit install
Running Tests
See docs/testing-guide.md for patterns, best practices, and gotchas.
# Unit/integration tests — parallel (~2.5 min)
uv run pytest tests/ -n $(( $(nproc) * 2 )) -m "not serial"
# Snapshot tests — must run serially
uv run pytest tests/ -m serial
# Update snapshots after UI changes
uv run pytest tests/snapshots/test_snapshots.py --snapshot-update
# Single file
uv run pytest tests/editor/test_code_editor.py
Metadata
Release files for textual-code 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| textual_code-0.5.0.tar.gz | 903.2 kB | Without provenance | Details for textual_code-0.5.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| textual_code-0.5.0-py3-none-any.whl | Python 3 | none | any | Details for textual_code-0.5.0-py3-none-any.whl |
Total release size: 1.1 MB
Release files / textual_code-0.5.0.tar.gz
| Download URL | textual_code-0.5.0.tar.gz |
|---|---|
| Size | 903.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8f82d4a7b9705a2d542644f3c8f4ae811c83013eff781586b854c0786834c81d
|
|
BLAKE2b-256 checksum How to use checksums |
339f8f8279b61a9c45289f5d5bd853b88c5cf0968ef879d81f04b1795eb1260b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / textual_code-0.5.0-py3-none-any.whl
| Download URL | textual_code-0.5.0-py3-none-any.whl |
|---|---|
| Size | 170.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9558f14b8f58207633cfaaff9e0ba606863e442dc738be8ae24edb4b3b4e772a
|
|
BLAKE2b-256 checksum How to use checksums |
1a519e3874420ba9c27d93f2c82f9ffacfde2c3e0f950295bf5df4420aa8d703
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for textual-code 0.5.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.