cat articles/herdr-cdd

cdd for herdr

Since my screen and tmux days, I have used a command named cdd. It is a small thing: if window:3 is working in ~/foo/bar, running cdd 3 simply does cd ~/foo/bar. That is all it does, but I use it constantly. I also like the command name cdd; it is easy to type. So I made cdd work with herdr too.

With herdr, there are three kinds of state to consider.

  • The directory of a tab or pane in the current workspace
  • The directory of a tab or pane in another workspace
  • The directory where an agent is working

I took those into account and made a zsh-only version with the following behavior. If you tell an AI coding agent to make a bash version or support another shell, I think it should be able to produce a similar implementation quickly.

  • Running only cdd opens a list of all working directories, filtered with fzf, and lets you move to the selected directory
  • cdd 3 moves to tab id 3 in the current workspace
  • cdd a3 moves to the cwd of the third agent in the agent list
  • cdd w3:p2 moves to pane id 2 in workspace id 3. This follows herdr's official notation, such as w3:p2
  • Pressing Tab in the usual places shows completion candidates and lets you select from them
  • It depends on jq and fzf, so those commands are required

cat related_articles/herdr-cdd.yaml

  1. herdr-tiny-fingers: tmux-fingers-style Copying for herdrherdr-tiny-fingers is a small plugin for copying URLs, SHAs, UUIDs, and similar text from a herdr terminal screen with short keys.
  2. Adding type hints to a Python project and getting value from type checkingAdding Python type hints and pyright to a machine learning project, with a low setup cost and immediately useful editor support and static checks.
  3. OpenAI API-Compatible Access Without Additional API Billing via CodexA Codex-authenticated OpenAI API-compatible server for Responses, Chat Completions, and image generation. Within the Codex subscription scope, it can be used without additional API usage billing.