1
4
Fork
You've already forked theylix
0
scripts/configs for helix editor, zellij, and various other cli tools for making a nifty, zen-mode, terminal-based ide
  • Shell 100%
2025年12月10日 20:48:04 +01:00
.config add regex-tui command to helix configs 2025年12月10日 20:48:04 +01:00
.local/bin Add regex-tui to txde script 2025年12月10日 20:47:07 +01:00
LICENSE Initial commit 2025年07月28日 21:34:50 +02:00
README.md Add regex TUI to README's dependencies list & Helix commands 2025年12月10日 20:30:48 +01:00

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/bin is in your $PATH
  • the files in .local/bin are 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 theylix script calls zellij delete-all-sessions -y to 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)
        • g opens Lazygit
        • b opens git blame (via Tig)
        • s opens LazySQL
        • r opens Slumber (REST client)
        • t opens a terminal session
        • x opens Regex TUI
      • ; opens Yazi file explorer
      • w writes to file
      • W writes to file and closes buffer
      • q closes the current buffer
      • Q force closes the current buffer, ignoring any unsaved changes
    • ctrl + y opens Yazi file explorer in normal mode
    • ctrl + g opens Lazygit in normal mode
    • ctrl + t opens a terminal in normal mode
    • X selects the above line in normal and select modes
    • ctrl + ; runs the flip_selections command in normal/select modes
    • 0 goes to line start in normal/select modes
    • a few other configs that I like... statusline, esc behaviors, etc.
  • Zellij
    • the Zellij session is named according to the following rules:
      • if file/directory arguments are provided to the theylix command, the session is named after the first argument's file/directory name
      • if no file/directory arguments are provided and the theylix command 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)
    • maps quit command to ctrl + shift + Q to prevent fat finger quitting the session
  • Yazi (file explorer)
    • (requires helix 25.07+) opens to the file in the current buffer
    • can open multiple files at once
    • ctrl + h opens files in horizontal splits
    • ctrl + v opens files in vertical splits
    • you can still use Yazi outside of theylix to open files in a new theylix session
  • Lazygit
    • o opens 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/txde as needed)
  • 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

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.