Documentation
¶
Overview ¶
Package automation lets another process drive a running app, as an end-to-end test runner or an agent does: list its windows, read what their native UI shows as elements, act on them, send pointer, wheel, key and text input, choose items of the application menu, evaluate scripts in pages, capture windows as PNG images, and wait for them to settle.
An app opts in by importing the package, as a file built for tests does:
//go:build e2e package main import _ "github.com/caelyreth/evil-mygo/plugins/automation"
Then it listens only when the environment variable MYGO_AUTOMATION names the path of a Unix domain socket, which only the user can open, and answers JSON requests on it, one per line:
MYGO_AUTOMATION=/tmp/app.sock ./app
Builds without the inspector of native UI (-tags mygo_noinspector, as mygo build makes for release) leave the plugin out: it never listens there. See docs/plugins/automation.md for the protocol, and for mygo-automation (cmd/mygo-automation), its command line client for agents.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
Source Files
¶
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
mygo-automation
command
Command mygo-automation drives a running MyGo app through plugins/automation's socket, made for AI coding agents: compact text snapshots of a window's elements with short refs (@e1), actions on them, and diffs of what the window shows once it settled.
|
Command mygo-automation drives a running MyGo app through plugins/automation's socket, made for AI coding agents: compact text snapshots of a window's elements with short refs (@e1), actions on them, and diffs of what the window shows once it settled. |