chore(cli): save screenshots to tmp dir when no path provided (#247)
* fix(cli): save screenshots to tmp dir when no path provided Instead of outputting base64 to stdout (which is not useful for most CLI use cases), screenshots without a path now save to ~/.agent-browser/tmp/screenshots/ with a generated filename and return the path. This makes the behavior more ergonomic for AI agents and CLI users alike. * cleanup * cleanup * just revert the cargo.lock version for now * refactor: extract getAppDir() from getSocketDir() * docs: improve screenshot help text consistency
This commit is contained in:
@@ -12,8 +12,8 @@ agent-browser snapshot # Get accessibility tree with refs
|
||||
agent-browser click @e2 # Click by ref from snapshot
|
||||
agent-browser fill @e3 "test@example.com" # Fill by ref
|
||||
agent-browser get text @e1 # Get text by ref
|
||||
agent-browser screenshot # Base64 png to stdout
|
||||
agent-browser screenshot page.png # Save to file
|
||||
agent-browser screenshot # Save to a temporary directory
|
||||
agent-browser screenshot page.png # Save to a specific path
|
||||
agent-browser close`} />
|
||||
|
||||
<h2>Traditional selectors</h2>
|
||||
|
||||
Reference in New Issue
Block a user