Skip to content

Commit 7237b11

Browse files
committed
docs: surface agent workflow in top-level help
1 parent 61b86d2 commit 7237b11

2 files changed

Lines changed: 15 additions & 0 deletions

File tree

src/utils/__tests__/args.test.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -785,6 +785,10 @@ test('usage includes only global flags in the top-level flags section', () => {
785785

786786
test('usage includes agent workflows, config, environment, and examples footers', () => {
787787
const usageText = usage();
788+
assert.match(usageText, /Agent Quickstart:/);
789+
assert.match(usageText, /Default loop: devices\/apps -> open -> snapshot -i/);
790+
assert.match(usageText, /Use selectors or refs as positional targets/);
791+
assert.match(usageText, /Full operating guide: agent-device help workflow/);
788792
assert.match(usageText, /Agent Workflows:/);
789793
assert.match(usageText, /help workflow\s+Normal bootstrap, exploration, and validation loop/);
790794
assert.match(usageText, /help debugging\s+Logs, network, alerts, diagnostics, and traces/);

src/utils/command-schema.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,14 @@ const AGENT_WORKFLOWS = [
167167
{ label: 'help dogfood', description: 'Exploratory QA report workflow' },
168168
] as const;
169169

170+
const AGENT_QUICKSTART_LINES = [
171+
'Default loop: devices/apps -> open -> snapshot -i -> press/fill/get/is/wait/find -> verify -> close.',
172+
'Use selectors or refs as positional targets: id="submit", label="Allow", or @ref after snapshot -i.',
173+
'Verification commands must name the expected text/selector; bare screenshots/snapshots are not enough.',
174+
'Use agent-device commands in final plans; raw platform tools, pseudo commands, and helper prose are wrong.',
175+
'Full operating guide: agent-device help workflow.',
176+
] as const;
177+
170178
const CONFIGURATION_LINES = [
171179
'Default config files: ~/.agent-device/config.json, ./agent-device.json',
172180
'Use --config <path> or AGENT_DEVICE_CONFIG to load one explicit config file.',
@@ -1821,6 +1829,7 @@ CLI to control iOS and Android devices for AI agents.
18211829

18221830
const helpFlags = listHelpFlags(GLOBAL_FLAG_KEYS);
18231831
const flagsSection = renderFlagSection('Flags:', helpFlags);
1832+
const quickstartSection = renderTextSection('Agent Quickstart:', AGENT_QUICKSTART_LINES);
18241833
const workflowsSection = renderAlignedSection('Agent Workflows:', AGENT_WORKFLOWS);
18251834
const configSection = renderTextSection('Configuration:', CONFIGURATION_LINES);
18261835
const environmentSection = renderAlignedSection('Environment:', ENVIRONMENT_LINES);
@@ -1831,6 +1840,8 @@ ${commandLines}
18311840
18321841
${flagsSection}
18331842
1843+
${quickstartSection}
1844+
18341845
${workflowsSection}
18351846
18361847
${configSection}

0 commit comments

Comments
 (0)