Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,19 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).

## [Unreleased]

### Added
- `zsh-edit-select` module (zsh): edit the command line like a text editor with
[zsh-edit-select](https://github.com/Michael-Matta1/zsh-edit-select) (Shift
selection, copy, cut, paste, undo, mouse selection). Installed from a pinned
clone (`v0.7.01`); on macOS `apply` builds the clipboard agent from that clone
with `make`, so a failed build degrades the module instead of surfacing on the
first shell start. On Linux the plugin still downloads its agent itself on the
first shell start, from its latest release instead of the pinned tag.
It loads after `autosuggestions` and `syntax-highlighting`.
The terminal needs key bindings for it, which omnishell does not write; the
cheatsheet lists them. A manual install of the plugin blocks the module until
its `source` line is removed.

## [0.10.0] - 2026-11-28

### Added
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@ copy is backed up. Only `apply`, `remove`, and `uninstall` change your system (a
| `pay-respects` | Suggest a corrected command after a failed one, run via the alias (a Rust `thefuck` alternative) — [iffse/pay-respects](https://github.com/iffse/pay-respects) | `pay-respects` (`brew`); else `git` + `cargo` fallback (needs Rust) | zsh, bash | `alias` (string, default `f`) |
| `atuin` | SQLite-backed shell history with fuzzy search, context and stats — [atuinsh/atuin](https://github.com/atuinsh/atuin). **Mutually exclusive with `fzf`** (both bind Ctrl+R) — enabling both is a config error. | `atuin` (`brew`, `pacman`); else `git` + `cargo` fallback (needs Rust) | zsh, bash | `bind_ctrl_r` (bool, default `true`), `bind_up_arrow` (bool, default `true`) |
| `ble-sh` | Autosuggestions and syntax highlighting for **bash** (until now zsh-only) via [ble.sh](https://github.com/akinomyoga/ble.sh). **Opt-in, bash only: it replaces parts of Readline** with its own line editor, so it **conflicts with `fzf` and `atuin`** (they rebind Ctrl+R and the completion keys; enabling either alongside is a config error) and may interact with your own `bind` settings. Loads after `completion` and `history`; sourced with `--attach=prompt` in interactive shells only. Built from a pinned clone (`v0.4.0-devel3`), so it needs `make`, `gawk` and `git` (on macOS: `brew install gawk`). A missing build is skipped silently. | pinned `git` clone built with `make` (no package manager ships it) | bash | — |
| `zsh-edit-select` | Edit the command line like a text editor: Shift+arrow selection, copy, cut, paste, undo/redo, type-to-replace and mouse selections — [Michael-Matta1/zsh-edit-select](https://github.com/Michael-Matta1/zsh-edit-select) (MIT). **It needs terminal key bindings** that send its key sequences to the shell (Ghostty, iTerm2, Kitty, WezTerm, VS Code: see the plugin's README; restart the terminal afterwards), and on macOS Accessibility permission for mouse selections (`edit-select setup-ax`). omnishell writes no terminal configuration. Loads after `completion`, `autosuggestions` and `syntax-highlighting`. **A manual install blocks it**: remove the plugin's `source` line from `~/.zshrc`, delete the old clone and stop its agent. `omnishell cheatsheet` lists the keys | pinned `git` clone (`v0.7.01`); on macOS `apply` builds the clipboard agent with `make` (Xcode Command Line Tools). **On Linux the plugin itself downloads its agent on the first shell start, from its latest GitHub release rather than the pinned tag** (checked against that release's `SHA256SUMS.txt`, not against anything omnishell pins); `edit-select build` compiles it from source instead | zsh | — |
| `modern-aliases` | Replace ls/cat/find with [eza](https://github.com/eza-community/eza), [bat](https://github.com/sharkdp/bat) and [fd](https://github.com/sharkdp/fd) when selected | `eza`, `bat`, `fd`; `eza` as a release binary where the manager has no package | zsh, bash | `replace` (`list<enum>` of `ls`, `cat`, `find`; default `["ls", "cat", "find"]`) |
| `colorized-man` | Syntax-highlighted man pages via [bat](https://github.com/sharkdp/bat) when present, with a zero-dependency `less` colour fallback | — (config only) | zsh, bash | — |
| `tealdeer` | A fast `tldr` client: short, practical command examples instead of long man pages — [tealdeer-rs/tealdeer](https://github.com/tealdeer-rs/tealdeer). The page cache is not filled by `apply`; `tldr` downloads it on first use | `tealdeer` (all managers); else a verified release binary (Linux x86_64, arm64, armv7) | zsh, bash | — |
Expand All @@ -232,8 +233,8 @@ copy is backed up. Only `apply`, `remove`, and `uninstall` change your system (a

`zsh-completions`, when enabled, loads before `completion` so its directory is on `fpath` when `compinit` runs.
`dynamic-completion` (bash) loads after `completion`. `ble-sh` (bash) loads after `completion` and `history`, and cannot be enabled together with `fzf` or `atuin`.
`you-should-use` loads after `modern-aliases`. `autosuggestions` and `syntax-highlighting` are zsh-only and always render last (with `syntax-highlighting` after `autosuggestions`); `fzf-tab`, when enabled,
loads after `completion`/`fzf` and before both of those. `tmux`, when enabled,
`you-should-use` loads after `modern-aliases`. `autosuggestions` and `syntax-highlighting` are zsh-only and render after every other module except `zsh-edit-select` (with `syntax-highlighting` after `autosuggestions`); `fzf-tab`, when enabled,
loads after `completion`/`fzf` and before both of those. `zsh-edit-select` loads after both, the order the plugin is written for. `tmux`, when enabled,
loads before the prompt modules (`starship`, `omnishell-prompt`).

### 🔨 Build prerequisites for the `git` fallback
Expand All @@ -258,6 +259,7 @@ omnishell does not install build tools — install them yourself and re-run
| 🦀 | `pay-respects` | `cargo` ≥ 1.85 |
| ⚙️ | `welcome` | `cmake` |
| ⚙️ | `ble-sh` | `make`, `gawk`, `git` |
| ⚙️ | `zsh-edit-select` | `git`; on macOS `make` and `clang` (Xcode Command Line Tools) |

> [!TIP]
> Distribution `cargo` packages are often too old. Install a current Rust
Expand Down
8 changes: 8 additions & 0 deletions modules/builtin/zsh-edit-select/cheatsheet.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{{ $mod := "Ctrl" }}{{ if eq .Platform "macos" }}{{ $mod = "Cmd" }}{{ end -}}
- `Shift` + arrow keys — select text on the command line; type or paste to replace the selection
- `{{ $mod }}+A` select all, `{{ $mod }}+C` copy, `{{ $mod }}+X` cut, `{{ $mod }}+Z` undo, `{{ $mod }}+Shift+Z` redo
- Paste with your terminal's own paste shortcut; it replaces a selection
- Run `edit-select config` to change the mouse behaviour and the key bindings
- Needs terminal key bindings that send these sequences to the shell (examples for Ghostty, iTerm2, Kitty, WezTerm and VS Code are in the plugin's README); restart the terminal afterwards
{{ if eq .Platform "macos" }}- Mouse selections need Accessibility permission for your terminal: run `edit-select setup-ax`
{{ end }}- A manual install of the plugin blocks this module: remove its `source` line from `~/.zshrc`, delete the old clone and stop its agent, otherwise nothing is loaded from here
28 changes: 28 additions & 0 deletions modules/builtin/zsh-edit-select/manifest.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
platforms = ["macos", "linux"]
shells = ["zsh"]
after = ["completion", "autosuggestions", "syntax-highlighting"]

[module]
id = "zsh-edit-select"
name = "zsh-edit-select"
description = "Edit the command line like a text editor: Shift selection, copy, cut, paste, undo and mouse selection (zsh)"
homepage = "https://github.com/Michael-Matta1/zsh-edit-select"
version = "1.0.0"
schema = 1

# No package manager ships the plugin, so it is always a pinned clone (MIT).
# It also needs a native clipboard agent. On macOS the agent is built here, from
# the pinned clone, so a failure shows up in `apply`; the plugin would otherwise
# download an unpinned binary from its latest release on the first shell start.
# The first run entry renders to an empty command on every other platform, which
# skips the build: on Linux the agent depends on the display server (X11 or
# Wayland) and its development libraries, so the plugin provisions it itself.
# Loading after autosuggestions and syntax-highlighting is the order the plugin
# is written for: it registers its hooks on the first prompt, after the widget
# wrappers those plugins install at load time exist.
[[packages.fallback]]
type = "git"
repo = "https://github.com/Michael-Matta1/zsh-edit-select.git"
dest = "{{.VendorDir}}/zsh-edit-select"
ref = "v0.7.01"
run = ["{{ if eq .Platform \"macos\" }}make{{ end }}", "-C", "{{.VendorDir}}/zsh-edit-select/impl-macos/backends/macos"]
3 changes: 3 additions & 0 deletions modules/builtin/zsh-edit-select/zsh.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
if [[ -r {{ pathjoin .VendorDir "zsh-edit-select" "zsh-edit-select.plugin.zsh" | shellquote }} ]]; then
source {{ pathjoin .VendorDir "zsh-edit-select" "zsh-edit-select.plugin.zsh" | shellquote }}
fi
7 changes: 7 additions & 0 deletions modules/testdata/zsh-edit-select/cheatsheet-zsh.golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
- `Shift` + arrow keys — select text on the command line; type or paste to replace the selection
- `Cmd+A` select all, `Cmd+C` copy, `Cmd+X` cut, `Cmd+Z` undo, `Cmd+Shift+Z` redo
- Paste with your terminal's own paste shortcut; it replaces a selection
- Run `edit-select config` to change the mouse behaviour and the key bindings
- Needs terminal key bindings that send these sequences to the shell (examples for Ghostty, iTerm2, Kitty, WezTerm and VS Code are in the plugin's README); restart the terminal afterwards
- Mouse selections need Accessibility permission for your terminal: run `edit-select setup-ax`
- A manual install of the plugin blocks this module: remove its `source` line from `~/.zshrc`, delete the old clone and stop its agent, otherwise nothing is loaded from here
3 changes: 3 additions & 0 deletions modules/testdata/zsh-edit-select/zsh.golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
if [[ -r '/home/j/.config/omnishell/vendor/zsh-edit-select/zsh-edit-select.plugin.zsh' ]]; then
source '/home/j/.config/omnishell/vendor/zsh-edit-select/zsh-edit-select.plugin.zsh'
fi
Loading
Loading