130 lines
4 KiB
Text
130 lines
4 KiB
Text
---
|
|
.title = "Flow Control",
|
|
.date = @date("2020-07-06T00:00:00"),
|
|
.author = "CJ van den Berg",
|
|
.layout = "index.shtml",
|
|
.draft = false,
|
|
---
|
|
|
|
## a programmer's text editor
|
|
|
|
Flow Control is under active development, but usually very stable.
|
|
|
|
[]($video.siteAsset('video/flow-control.mp4').controls(true))
|
|
|
|
## 🚀 Features
|
|
- **Lightning Fast** TUI with ≤6ms response times
|
|
- **Tree-sitter** powered syntax highlighting
|
|
- **Language Server Protocol** pre configured support for most language servers
|
|
- Multi-cursor editing & mouse support
|
|
- Cross-platform (Linux/macOS/Windows/Android)
|
|
- VSCode/Vim keybindings + custom schemes
|
|
- Hybrid rope/piece-table buffer system
|
|
|
|
## Requirements
|
|
- A modern terminal with 24bit color and, ideally, kitty keyboard protocol support. Kitty,
|
|
Foot and Ghostty are the only recommended terminals at this time. Most other terminals
|
|
will work, but with reduced functionality.
|
|
- NerdFont support. Either via terminal font fallback or a patched font.
|
|
- Linux, MacOS, Windows, Android (Termux) or FreeBSD.
|
|
- A UTF-8 locale
|
|
|
|
## 📦 Installation
|
|
|
|
Fetch and install the latest release to `/usr/local/bin` with the installation helper script:
|
|
|
|
```
|
|
curl -fsSL https://flow-control.dev/install | sh
|
|
```
|
|
|
|
Install latest nightly build and (optionally) specify the installation destination:
|
|
|
|
```
|
|
curl -fsSL https://flow-control.dev/install | sh -s -- --nightly --prefix ~/.local/bin
|
|
```
|
|
|
|
See all avalable options for the installer script:
|
|
|
|
```
|
|
curl -fsSL https://flow-control.dev/install | sh -s -- --help
|
|
```
|
|
|
|
### Prebuilt Binaries
|
|
- Stable: [Releases](https://github.com/neurocyte/flow/releases/latest)
|
|
- Nightly: [Nightly Builds](https://github.com/neurocyte/flow-nightly/releases/latest)
|
|
|
|
Or check your favorite local system package repository.
|
|
|
|
### Build from Source
|
|
```bash
|
|
# Basic build
|
|
zig build -Doptimize=ReleaseSafe
|
|
|
|
# Cross-compile examples
|
|
zig build -Dtarget=x86_64-windows --prefix zig-out/win64
|
|
zig build -Dtarget=aarch64-linux-musl --prefix zig-out/arm-linux
|
|
```
|
|
|
|
The binary is:
|
|
|
|
```
|
|
zig-out/bin/flow
|
|
```
|
|
|
|
It is statically built (by default) and contains all the required tree-sitter parsers
|
|
and queries. No additional runtime files are required. Place it in your path for convenient
|
|
access.
|
|
|
|
## Configuration
|
|
|
|
Configuration is mostly dynamically maintained with various commands in the UI.
|
|
It is stored under the standard user configuration path. Usually `~/.config/flow`
|
|
on Linux. %APPDATA%\Roaming\flow on Windows.
|
|
|
|
Logs, traces and per-project most recently used file lists are stored in the
|
|
standard user application state directory. Usually `~/.local/state/flow` on
|
|
Linux and %APPDATA%\Roaming\flow on Windows.
|
|
|
|
Kitty, Ghostty and most other terminals have default keybindings that conflict
|
|
with common editor commands. We highly recommend rebinding them to keys that are
|
|
not generally used inside TUI applications.
|
|
|
|
For Kitty rebinding `kitty_mod` is usually enough:
|
|
```
|
|
kitty_mod ctrl+alt
|
|
```
|
|
|
|
## 🛠️ Basic Usage
|
|
```bash
|
|
flow file.zig:42 # Open at line 42
|
|
flow --language zig CMakeLists.txt # Force file type
|
|
flow --list-languages # Show all supported languages
|
|
flow --help # List of command line options
|
|
```
|
|
|
|
## ⌨️ Key Controls
|
|
| Command | Action |
|
|
|--------------------|----------------------|
|
|
| `F4` | Switch input mode |
|
|
| `Ctrl+Shift+P` | Command palette |
|
|
| `Ctrl+F2` | View all keybindings |
|
|
|
|
Run the `Edit keybindings` command to save the current keybinding mode to a
|
|
file and open it for editing. Save your customized keybinds under a new name
|
|
in the same directory to create an entirely new keybinding mode. Keybinding
|
|
changes will take effect on restart.
|
|
|
|
|
|
## 🛣️ Roadmap
|
|
**In Development**:
|
|
- LSP completion support
|
|
- Persistent undo/redo
|
|
- File watcher integration
|
|
|
|
**Future**:
|
|
- Collaborative editing
|
|
- Plugin system
|
|
- Multi-terminal sessions
|
|
|
|
## 💬 Community
|
|
Join our [Discord server](https://discord.com/invite/4wvteUPphx) or discuss on [GitHub Discussions](https://github.com/neurocyte/flow/discussions)
|