A stripped-down command-line text editor with a built-in directory browser. Find a file, preview it, and edit it without leaving the terminal.
- Directory browser: move through folders with the arrow keys.
- File preview: see a file's contents next to the listing before you open it.
- Editor: soft-wrapped lines, paging, and simple C syntax highlighting (types, control flow,
return, numbers and function calls). - Small: a single C file with no dependencies. It runs on Linux and macOS.
You need a C compiler and make.
git clone https://github.com/maelswarm/pixt.git
cd pixt
makeTo put pixt on your PATH:
sudo make install # installs to /usr/local/bin
make install PREFIX="$HOME/.local" # or installs into your home directorymake uninstall removes it and make clean deletes the build.
Run pixt from the folder you want to start in:
cd ~/projects
pixtpixt opens in browser mode. Highlight a file with the arrow keys and press → to preview it. Then press Enter to edit it.
| Key | Action |
|---|---|
| ↑ / ↓ | Move the selection. Long folders are split into pages and the selection moves between them. |
| → | Open the selected folder, or preview the selected file |
| ← | Go to the parent folder |
| Enter | Edit the file being previewed |
| Ctrl+N | Start a new, empty file (you name it when you save) |
| Esc, then Enter | Quit |
| Key | Action |
|---|---|
| Arrow keys | Move the cursor |
| Ctrl+Y / Ctrl+V | Page up / page down |
| Tab | Insert four spaces |
| Ctrl+O | Save (asks for a file name) |
| Ctrl+X | Close the editor without saving and go back to the browser |
| Esc, then Enter | Quit pixt without saving |
Ctrl+O shows a prompt at the bottom of the screen:
- Type a file name and press Enter. A plain name is saved in the current folder. Absolute paths also work.
- Press Enter without typing anything to save over the file you opened (its name is shown in parentheses).
- Press Ctrl+C to cancel and go back to the editor.
After a successful save, pixt returns to the browser. If the file can't be written, the prompt says so and asks again.
- pixt never asks before quitting or closing the editor, so save first.
- Tabs are shown as four spaces. On save, every run of four spaces is written as a tab, including spaces you typed.
- Trailing spaces at the end of each line are removed when a file is opened.
- pixt is meant for plain ASCII text. Multibyte UTF-8 characters can put the cursor out of line with the text, and binary files aren't supported.
To ask for a new feature, open an issue on this repository.

