Skip to main content

Code editor for who don't know how to use vi

Project description

Textual Code

Code editor for who don't know how to use vi

Screenshot

[!WARNING]
This project is in the early stages of development. It is not ready for use yet.

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+S to save and Ctrl+F to 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

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:

[!TIP] We recommend using uvx as it requires no separate installation.

# Using pip
pip install textual-dev
textual keys

# Run without installing (recommended)
uvx --from textual-dev textual keys

Installation

[!TIP] We recommend using uv for installation and management.

# 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

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

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/test_snapshots.py --snapshot-update

# Single file
uv run pytest tests/test_code_editor.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

textual_code-0.2.0.tar.gz (595.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

textual_code-0.2.0-py3-none-any.whl (106.8 kB view details)

Uploaded Python 3

File details

Details for the file textual_code-0.2.0.tar.gz.

File metadata

  • Download URL: textual_code-0.2.0.tar.gz
  • Upload date:
  • Size: 595.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","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}

File hashes

Hashes for textual_code-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6c4f07eef92d8c2770db757c951da74a2687f169a07730403d693c37c2bd5667
MD5 aadf415bcdbb56e786c124d01e945ad1
BLAKE2b-256 6ead4d0b5afd7c2a6f0b97651e2d5191a90aa8734a4a7a7c782677415c258846

See more details on using hashes here.

File details

Details for the file textual_code-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: textual_code-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 106.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","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}

File hashes

Hashes for textual_code-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 614e875ae06b3a64c558baf27b581cdf76217e5abc75f08d38c2541f008b02ea
MD5 73a377e666a79475b2fec4b39fbff1f8
BLAKE2b-256 042d7112d1ea895bb85fc6403535d494a9282342631c262e64846a1f24288160

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page