Back to surfaces Linux · Wayland (Sway)

Sway + rofi launcher

A set of small shell scripts that put your agents on Sway keybindings: a rofi switcher over the sessions of every host, launchers that start an agent on a Linear issue or GitHub PR, and a new-session form. They call the pohunek CLI and nothing else, so they install on their own; pohunek-work is optional. Sway is the window manager they ship for today, and the same scripts are meant to drive other window managers too.

Shipped · launchers-v0.4.0
Features

What it does

Switch between agents with $mod+p

pohunek-rofi lists the sessions of every reachable host with project, branch, agent, state and activity. Pick one or several: their attach terminals open, and the attach windows you did not pick close, which only detaches you. --filter key=value narrows the list before it reaches rofi, for example only blocked sessions.

Closing a window detaches, never stops

The switcher only opens terminals that run pohunek attach. Closing one detaches you; the agent keeps running on its durable worker.

Start an agent on an issue or a PR

pohunek-rofi-issue <project> linear lists your actionable Linear issues and pohunek-launch-issue starts an agent on the one you pick, with its prompt rendered by pohunek prompt render and the issue link stored as session metadata. pohunek-launch-pr does the same for a GitHub pull request. The GitHub issue source goes through pohunek-work.

New session form on $mod+n

pohunek-new-session opens the pohunek-work new-session form in your terminal. This binding is the one part that needs pohunek-work; pohunek-work setup sway adds it.

Install

Get it running

Requirements

pohunek installed and running, plus rofi, swaymsg, python3 and a terminal emulator.

shell
command -v pohunek rofi swaymsg python3

Get the scripts: release archive

Verified download of the launcher release.

shell
gh release download launchers-v0.4.0 -R zajca/pohunek-work -p 'pohunek-launchers-0.4.0-noarch.tar.gz*'
sha256sum -c pohunek-launchers-0.4.0-noarch.tar.gz.sha256
gh attestation verify pohunek-launchers-0.4.0-noarch.tar.gz --repo zajca/pohunek-work
tar -xzf pohunek-launchers-0.4.0-noarch.tar.gz
cd pohunek-launchers-0.4.0-noarch

Or get the scripts: from source

The same files live in the launchers/ directory of the repository.

shell
git clone https://github.com/zajca/pohunek-work.git
cd pohunek-work/launchers

Install them (from either directory)

Copies the scripts, launcher.conf and prompt templates into the same XDG paths pohunek-work setup uses, and binds the switcher to $mod+p. Existing config files are kept. Your sway config must include ~/.config/sway/config.d/*, and terminal= in launcher.conf names your terminal.

shell
bin=${XDG_DATA_HOME:-$HOME/.local/share}/pohunek/bin
cfg=${XDG_CONFIG_HOME:-$HOME/.config}
install -d "$bin" "$cfg/pohunek/prompts" "$cfg/sway/config.d"
install -m 755 pohunek-rofi pohunek-rofi-issue pohunek-launch-issue pohunek-launch-pr pohunek-new-session "$bin/"
install -m 644 lib.sh "$bin/"
cp -n templates/launcher.conf "$cfg/pohunek/"
cp -n templates/prompts/*.tmpl "$cfg/pohunek/prompts/"
printf 'bindsym $mod+p exec exec %s/pohunek-rofi\n' "$bin" > "$cfg/sway/config.d/pohunek.conf"
swaymsg reload

Or let pohunek-work do it

With pohunek-work installed (see the Terminal TUI page), setup writes the same files and adds the $mod+n new-session binding; doctor checks every requirement.

shell
pohunek-work setup        # scripts, launcher.conf, prompts and the sway drop-in
pohunek-work doctor
Notes

Every surface is a client of the same public CLI and protocol. See the other surfaces or the docs. Project home: https://github.com/zajca/pohunek.