Skip to content

jobrunner

Usage
jobrunner [-t <tool>] [<subcommand>] [<name>] [<command>...]
jr [-t <tool>] [<subcommand>] [<name>] [<command>...]

Runs, lists, inspects, re-attaches to, and terminates named background jobs using tmux or GNU screen as the process engine. Unlike bkg and detach, which discard output, a jobrunner job keeps a live terminal you can return to later — it survives closing the shell, and attach restores it in any subsequent session. Run and manage named background jobs. Jobs are detached from the shell and backed by tmux (preferred) or GNU screen.

If the job name is omitted when starting a new job (e.g. jobrunner sleep 1), a memorable, random name (like sleepy-badger) will be generated.

Exit Status:

0 Command succeeded, or no jobs are running
1 Invalid arguments, or the named job does not exist
127 neither tmux nor screen is installed
Notes:
Detach from an attached job with Ctrl-A then D; the job keeps running.
Commands are executed directly rather than through a shell, so pipes and
redirections must be wrapped explicitly, e.g.
`jobrunner run sync fish -c 'a | b'`.
Examples
jobrunner run -n build make -j8
jobrunner sleep 1000
jobrunner -t screen run -n backup rsync -a ./data remote:/backup/
jobrunner list
jobrunner logs build
jobrunner build
jobrunner kill build

Dependencies: tmux, screen, __jobrunner_sessions

Used by: jr