summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-02-10 09:17:40 +0200
committerPaul Buetow <paul@buetow.org>2026-02-10 09:17:40 +0200
commit1b62f0bddc639a9b30ff95ea2326e52f9b1e7528 (patch)
tree64586d4415dab2a267d6c0667e2283a07665b79f /docs
parent8b04018b1836730c9efe96fabd67ffd48c00865d (diff)
Fix hexai-tmux-edit to open in current working directory
hexai-tmux-edit was opening in the wrong directory because the tmux popup wasn't being told which directory to use. This fix: - Updates bind-key example to cd into pane's current path - Passes working directory to popup via -d flag using os.Getwd() - Updates all documentation with corrected bind-key examples Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Diffstat (limited to 'docs')
-rw-r--r--docs/configuration.md2
-rw-r--r--docs/tmux.md2
-rw-r--r--docs/usage.md2
3 files changed, 3 insertions, 3 deletions
diff --git a/docs/configuration.md b/docs/configuration.md
index 52e0689..939b001 100644
--- a/docs/configuration.md
+++ b/docs/configuration.md
@@ -141,4 +141,4 @@ Hexai Tmux Edit (popup editor)
```
- Built-in agents: `claude`, `cursor`, `amp`, `aider`. See [config.toml.example](../config.toml.example) for all fields.
-- Tmux keybinding: `bind e run-shell -b "hexai-tmux-edit --pane '#{pane_id}'"`
+- Tmux keybinding: `bind e run-shell -b "cd '#{pane_current_path}' && hexai-tmux-edit --pane '#{pane_id}'"`
diff --git a/docs/tmux.md b/docs/tmux.md
index e7c99dd..b851296 100644
--- a/docs/tmux.md
+++ b/docs/tmux.md
@@ -84,7 +84,7 @@ The editor opens as a tmux popup overlay, pre-filled with any existing prompt te
Add this keybinding to `~/.tmux.conf`:
```
-bind e run-shell -b "hexai-tmux-edit --pane '#{pane_id}'"
+bind e run-shell -b "cd '#{pane_current_path}' && hexai-tmux-edit --pane '#{pane_id}'"
```
Then press `prefix + e` in any pane running an AI agent. Hexai auto-detects the agent, extracts any existing prompt text, and pre-fills the editor. After saving and closing, the edited text is sent back to the agent's pane.
diff --git a/docs/usage.md b/docs/usage.md
index 387ad34..4d1b50b 100644
--- a/docs/usage.md
+++ b/docs/usage.md
@@ -183,7 +183,7 @@ Additional agents can be added via `[tmux_edit.agents]` in config.toml without c
Add to `~/.tmux.conf`:
```
-bind e run-shell -b "hexai-tmux-edit --pane '#{pane_id}'"
+bind e run-shell -b "cd '#{pane_current_path}' && hexai-tmux-edit --pane '#{pane_id}'"
```
The `#{pane_id}` is expanded by tmux to the active pane at keypress time, so the popup editor always knows which pane to send text back to.