`tobi` is a small utility for persistent terminals across your devices.
`tobi` keeps commands running in detachable sessions across your devices.
`tobi -- nu` spins up a daemon with the command running. the daemon will
automatically detach if you close your terminal window. detached sessions will
be cleaned up after 24h of them being detached. `tobi host.id -- nu` creates
a session on that target, and since host is optional you can `tobi .id -- nu`
to create a session with that specific id! hosts can carry a user
(`tobi you@host.id`) when your ssh config doesn't already set one.
(`tobi you@host.id`) when your ssh config doesn't already set one, or you want
to use a different user.
you can access it from any of your other devices on your tailscale network by
running `tobi`, which opens up a fuzzy selector with all the sessions across
your network. you can also just do `tobi hx`, `tobi host.<TAB>` or `tobi hs.id`
to attach a session using fuzzy search.
unlike tmux, tobi doesn't nest. running tobi inside a tobi session will just
replace your session with the target session.
replace your session with the target session. multiple viewers can attach to
a single tobi session (in that case minimum terminal size will be used).
offline hosts (machines that are off your tailscale network) are hidden from
the picker by default; set `TOBI_OFFLINE=1` to show them at the bottom.
## requirements
transport: tobi runs `tssh` if it's in PATH, otherwise `ssh`. both read your
`~/.ssh/config` as usual. if you run `tsshd` on your hosts and `tssh` locally,
set `UdpMode yes` per host for mosh-style roaming on cellular or unstable
wifi — sessions, spawn and attach all ride it.
tobi uses `tssh` if it's in PATH, otherwise `ssh`. `tailscale` binary is only
required for discovery to function, nothing else.
## installation
there is a nix flake so you can use that, just do
`nix profile add git+https://tangled.org/ptr.pet/tobi`. otherwise get go and
compile it!
if you run target tobi to a host that doesn't have it, then tobi will install
itself onto the user's `~/.local/bin` (or equivalent) automatically, or upgrade
an outdated tobi if the one on the target host is a different version.
if you use the nix package or build with carriers (see ./scripts) then you can
infect other machines with tobi as long as the os/arch is supported, which are
linux amd64, arm64 & macos arm64.
## acknowledgements
charm ui libs and tailscale. llms were also used while making this (i leave
how much up to the reader if you care ^^).