Skip to content
Stuck? Ask Ghostex AI from the sidebar menu.Learn how
Ghostex
Esc
↑↓navigate↵open⌘Jpreview
On this page

Other computers

Run agents and coordinator threads on another machine, and hand conversations over between computers.

Ghostex can control agents on other computers: a desktop at home, a build server, or a Linux box in the cloud. Their projects and sessions join yours in one sidebar, and their terminals stream into your window. A coordinator’s threads can run on them and report back, agents can message sessions across computers, and you can hand a conversation over to another computer.

Connect a computer

The easiest way, when both computers have Ghostex:

Open Connect a Computer on both

In the sidebar menu (the three lines at the top of the sidebar), choose Connect a Computer, on both computers.

Copy one code, paste it on the other

Each window shows its own code with Copy. Copy the code on one computer, paste it into the box on the other, and click Connect.

Approve

Both computers show the same three words. Click Approve only if they match.

The finished window offers Connect both ways, so the other computer can reach this one too.

The code is this computer’s own: it names the computer and carries a one-time secret. It works once and lapses after five minutes, and Ghostex shows a new one when it does. You can find it in Connect a Computer (sidebar menu, or Settings > Remote and its Connect a Computer button), and also when you choose Add a computer in Settings > Remote. Phones have their own window: Connect a Phone.

Connect a server that has no Ghostex app

A headless server (a Linux box in the cloud, say) has no window to show a code in. Its terminal can show one instead. This needs Ghostex’s server, gxserver, to be running there with Easy Connect on (ghostex tailcat enable turns it on).

Print the code on the server

In the server’s own terminal (over SSH is fine, but not inside a Ghostex session), run ghostex computer-code. gxserver computer-code does the same. It prints the server’s code and keeps running.

Paste it on your computer

On your computer, open Connect a Computer, paste the code into The other computer’s code, and click Connect. Your computer shows three words.

Compare the words and approve in the terminal

The server’s terminal shows the same three words and asks Approve it? [y/N]. Type y if they match, or n if they don’t. After you approve, the command stops and your computer finishes connecting.

Add --copy to also put the code on your clipboard (over SSH, your terminal’s clipboard, if it allows that). ghostex computer-code --once (or --json) only prints the code and exits. Then approve the new computer in the Ghostex app, or on a paired phone, within a minute. Left running, the command also stops by itself after 10 minutes with nobody waiting.

To use SSH instead, choose Use SSH details in the same window and enter the address, username and password. A Windows computer needs Ghostex installed and SSH turned on.

Use your computers as one

Agents and threads talk across computers

  • Threads on another computer. A coordinator can run its threads on any computer you’ve connected, and they report back to it just like threads on this one. Ask it: “Run this in a thread on my Windows PC.”
  • Agents message each other. Any agent can message, start and read sessions on your other computers, and their agents can do the same on this one.

Both computers need Ghostex 10.44 or later. To stop agents using a computer, turn Agent access off in its Edit dialog (under Advanced).

Hand a conversation over to another computer

Right-click a session, choose Handoff / Export > Handoff to an agent, then Destination > Change… and pick the other computer. A new session starts there with the conversation, and the files it used, attached. Use it when one machine is busy or out of memory. Only the conversation moves, so commit or push your code changes first, and close the old session when you’re done with it.

One sidebar for all of them

Every connected computer’s projects are in the same list. A project on several computers (the same git repository) is one entry with the sessions of all of them, and each session shows which computer it runs on. If you see a tab per computer instead, turn off Settings > Sidebar & Sessions > Separate by machine. To put a project on a computer that doesn’t have it yet, right-click it and choose Clone on…. More in Projects.

Good to know

  • VS Code, the Browser, and links to localhost work through the other computer, so you can edit its files and open its dev servers.
  • Each computer keeps running its own agents, even when you disconnect.
  • When a computer can’t connect, Ghostex says why, with Reconnect and Details. A chat on a computer that is off says so above the chat box, and a message you send waits until that computer is back.
  • Settings > Remote lists the computers this one connects to, and the phones and computers that can reach it.

Keep it up to date

You don’t need to go to the other computer to update it. When a newer Ghostex is out, its tile in Settings > Remote (or its tab’s right-click menu) offers Update to that version. Its sessions keep running while it updates. You can also pick the computer at the top of Settings > Updates to update its agents and tools.

Turn on Keep this machine up to date on the computer’s tile to have it install updates by itself while none of its agents is working (macOS and Windows; on Linux, install the new package there).

To keep your settings the same on both computers, see Sync between computers.

Was this page helpful?