scripts/configs for helix editor, zellij, and various other cli tools for making a nifty, zen-mode, terminal-based ide
- Shell 100%
| .config | add regex-tui command to helix configs | |
| .local/bin | Add regex-tui to txde script | |
| LICENSE | Initial commit | |
| README.md | Add regex TUI to README's dependencies list & Helix commands | |
theylix
Scripts/configs for helix editor, zellij, and various other cli tools for a nice zen-mode terminal-based IDE
Dependencies
| Name | Description |
|---|---|
| Helix | Text editor |
| Zellij | Terminal multiplexer |
| Yazi | File explorer |
| Serpl | Global find and replace |
| Slumber | REST client |
| LazySQL | SQL client |
| Lazygit | Git client |
| Tig | Git interface, used for git blame (requires helix 25.07+) |
| Regex TUI | Regex testing |
Assumptions / Setup
- This is going for a zen-mode experience with simple configs and a decently integrated feel between the various tools. There's others (yazelix, zide) that go for multi-pane layouts.
You can just drop this repo's files into your home directory (preserving the directory structure... plz don't overwrite your ~/.config and ~/.local/bin directories), but you'll need to make sure the following are true:
.local/binis in your$PATH- the files in
.local/binare executable
However, you may want to modify the files in this repo for various reasons:
- Adding your own configs for Helix, etc.
- I'm only using Zellij for this, so these desisions work for me but might not for you:
- All Zellij keybindings are disabled (except for quitting the Zellij session, mentioned below). Yazelix features Helix-friendly keybindings for Zellij, in case you want to interact directly with Zellij.
- The
theylixscript callszellij delete-all-sessions -yto prevent collisions with dead Zellij session names (see below for session name behaviors). I'll likely change this once Helix implements session persistence, but for now I don't see a reason to allow the Zellij sessions to be resurrected.
- Yazi file opener currently opens all files with helix. You probably want to add opener configs so that non-text mime types get opened with other software.
- I found the bottom line in Lazygit to be annoying, so I hid it. You can see keybindings via
?, but you still might want to reenable the bottom line.
Usage
Usage: theylix [OPTION] [ARGS]
Args: Arguments should be a list of filepaths.
Existing files will be opened; otherwise, empty Helix buffers will be opened.
If any options are provided, you must include at least one file argument.
If no options are provided:
- a new Theylix session will be created
- if no arguments are provided, Helix will open to the current directory
- you can provide a single directory argument instead of a list of filepaths,
in which case Helix will open to that directory
Options: Only 1 option allowed; subsequent options will be interpreted as filenames.
--help Display this helper text
-a, --attach Open files in the current Theylix session
-h, --hsplit Open files with a horizontal split in the current Theylix session
-v, --vsplit Open files with a vertical split in the current Theylix session
Features
- Helix
- new options in the space picker
e(short for "extras") opens a new picker window for accessing the cli tools, which open in floating Zellij panes/opens Serpl (global find and replace)gopens Lazygitbopensgit blame(via Tig)sopens LazySQLropens Slumber (REST client)topens a terminal sessionxopens Regex TUI
;opens Yazi file explorerwwrites to fileWwrites to file and closes bufferqcloses the current bufferQforce closes the current buffer, ignoring any unsaved changes
ctrl + yopens Yazi file explorer in normal modectrl + gopens Lazygit in normal modectrl + topens a terminal in normal modeXselects the above line in normal and select modesctrl + ;runs theflip_selectionscommand in normal/select modes0goes to line start in normal/select modes- a few other configs that I like... statusline,
escbehaviors, etc.
- new options in the space picker
- Zellij
- the Zellij session is named according to the following rules:
- if file/directory arguments are provided to the
theylixcommand, the session is named after the first argument's file/directory name - if no file/directory arguments are provided and the
theylixcommand is run from a directory within a git repository, the session is named after the git repository - otherwise, the session is given a random name (Zellij's default behavior)
- if file/directory arguments are provided to the
- maps quit command to
ctrl + shift + Qto prevent fat finger quitting the session
- the Zellij session is named according to the following rules:
- Yazi (file explorer)
- (requires
helix 25.07+) opens to the file in the current buffer - can open multiple files at once
ctrl + hopens files in horizontal splitsctrl + vopens files in vertical splits- you can still use Yazi outside of theylix to open files in a new theylix session
- (requires
- Lazygit
oopens the selected file in a new Helix buffer- (requires
helix 25.07+) opens to the repository of the current buffer
- Slumber (REST client)
- REST collections for Slumber should be stored at
~/.config/slumber/collections.yml(or modify.local/bin/txdeas needed)
- REST collections for Slumber should be stored at
- Serpl (global find and replace)
- (requires
helix 25.07+) if the current buffer is a file within a git repository, it searches within that repository... otherwise, it searches within the directory that the Helix session was opened from
- (requires
Potential issues
- The Helix keybinding for
ctrl + ;may give you some grief. Particularly, if you're using Wezterm, you'll need to add this config to your.wezterm.lua:config.enable_kitty_keyboard = true - It's possible for floating Zellij panes (used for everything except Helix) to get hidden. If this happens, the pane might reappear as a result of certain actions like opening a file via the Yazi file explorer. I'm not aware of any broken functionality related to this, but if you run into any please create an issue.