pull

Download the agent's workspace files from a running sandbox to your local machine, excluding ClawRun-managed config files.

Usage

clawrun pull <instance>

Pull agent runtime state from the sandbox to your local machine. The sandbox must already be running. This command does not start a stopped sandbox.

Arguments

ArgumentRequiredDescription
instanceYesThe instance name

Behavior

  1. Connects to the running sandbox
  2. Determines the agent's home directory via echo $HOME
  3. Lists all files under the agent's runtime directory ($HOME/{sandboxRoot}/agent/)
  4. Filters out "locally owned" files, which are configuration files managed by ClawRun (e.g., config.toml) that the agent declares via getLocalOwnedFiles(). These are excluded because they are generated by the CLI and should not be overwritten
  5. Downloads remaining files via readFile() and writes them to the local instance directory

Files are saved to ~/.clawrun/<instance-name>/agent/, mirroring the sandbox directory structure. The command prints a summary with the count of files pulled and the local destination path.

If no pullable files are found (only locally-owned files exist), the command warns and exits.

Examples

clawrun pull my-instance