Skip to content

Commit 5ec239e

Browse files
committed
chore: update readme for 0.0.64
1 parent 528375e commit 5ec239e

5 files changed

Lines changed: 42 additions & 35 deletions

File tree

README.md

Lines changed: 25 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ playwright-cli --help
3232
Claude Code, GitHub Copilot and others will use the locally installed skills.
3333

3434
```bash
35-
playwright-cli install-skills
35+
playwright-cli install --skills
3636
```
3737

3838
### Skills-less operation
@@ -105,13 +105,13 @@ Playwright CLI will use a dedicated persistent profile by default. It means that
105105
your cookies and other storage state will be preserved between the calls. You can use different
106106
instances of the browser for different projects with sessions.
107107

108-
Following will result in two browsers with separate profiles being available. Pass `--session` to
108+
Following will result in two browsers with separate profiles being available. Pass `-s=` to
109109
the invocation to talk to a specific browser.
110110

111111
```bash
112112
playwright-cli open https://playwright.dev
113-
playwright-cli --session=example open https://example.com
114-
playwright-cli session-list
113+
playwright-cli -s=example open https://example.com
114+
playwright-cli list
115115
```
116116

117117
You can run your coding agent with the `PLAYWRIGHT_CLI_SESSION` environment variable:
@@ -120,16 +120,14 @@ You can run your coding agent with the `PLAYWRIGHT_CLI_SESSION` environment vari
120120
PLAYWRIGHT_CLI_SESSION=todo-app claude .
121121
```
122122

123-
Or instruct it to prepend `--session` to the calls.
123+
Or instruct it to prepend `-s=` to the calls.
124124

125125
Manage your sessions as follows:
126126

127127
```bash
128-
playwright-cli session-list # list all sessions
129-
playwright-cli session-stop [name] # stop session
130-
playwright-cli session-restart [name] # restart session
131-
playwright-cli session-stop-all # stop all sessions
132-
playwright-cli session-delete [name] # delete session data along with the profiles
128+
playwright-cli list # list all sessions
129+
playwright-cli close-all # close all browsers
130+
playwright-cli kill-all # forcefully kill all browser processes
133131
```
134132

135133
<!-- BEGIN GENERATED CLI HELP -->
@@ -152,6 +150,7 @@ playwright-cli upload <file> # upload one or multiple files
152150
playwright-cli check <ref> # check a checkbox or radio button
153151
playwright-cli uncheck <ref> # uncheck a checkbox or radio button
154152
playwright-cli snapshot # capture page snapshot to obtain element ref
153+
playwright-cli snapshot --filename=f # save snapshot to specific file
155154
playwright-cli eval <func> [ref] # evaluate javascript expression on page or element
156155
playwright-cli dialog-accept [prompt] # accept a dialog
157156
playwright-cli dialog-dismiss # dismiss a dialog
@@ -187,7 +186,9 @@ playwright-cli mousewheel <dx> <dy> # scroll mouse wheel
187186
188187
```bash
189188
playwright-cli screenshot [ref] # screenshot of the current page or element
189+
playwright-cli screenshot --filename=f # save screenshot with specific filename
190190
playwright-cli pdf # save page as pdf
191+
playwright-cli pdf --filename=page.pdf # save pdf with specific filename
191192
```
192193
193194
### Tabs
@@ -250,8 +251,8 @@ playwright-cli video-stop [filename] # stop video recording
250251
### Install
251252
252253
```bash
254+
playwright-cli install --skills # install skills
253255
playwright-cli install-browser # install browser
254-
playwright-cli install-skills # install skills
255256
```
256257
257258
### Configuration
@@ -260,18 +261,22 @@ playwright-cli install-skills # install skills
260261
playwright-cli config [options] # configure session settings
261262
playwright-cli open --browser=chrome # use specific browser
262263
playwright-cli open --extension # connect via browser extension
264+
playwright-cli open --persistent # use persistent profile
265+
playwright-cli open --profile=<path> # use custom profile directory
263266
playwright-cli open --config=file.json # use config file
267+
playwright-cli close # close the browser
268+
playwright-cli delete-data # delete user data for default session
264269
```
265270
266271
### Sessions
267272
268273
```bash
269-
playwright-cli --session=name <cmd> # run command in named session
270-
playwright-cli session-list # list all sessions
271-
playwright-cli session-stop [name] # stop session
272-
playwright-cli session-restart [name] # restart session
273-
playwright-cli session-stop-all # stop all sessions
274-
playwright-cli session-delete [name] # delete session data and profiles
274+
playwright-cli -s=name <cmd> # run command in named session
275+
playwright-cli -s=name close # stop a named browser
276+
playwright-cli -s=name delete-data # delete user data for named browser
277+
playwright-cli list # list all sessions
278+
playwright-cli close-all # close all browsers
279+
playwright-cli kill-all # forcefully kill all browser processes
275280
```
276281
<!-- END GENERATED CLI HELP -->
277282
@@ -426,7 +431,8 @@ Playwright CLI will load config from `playwright-cli.json` by default so that yo
426431
427432
</details>
428433
429-
## Environment
434+
<details>
435+
<summary>Configuration via env</summary>
430436
431437
| Environment |
432438
|-------------|
@@ -472,3 +478,4 @@ Playwright CLI will load config from `playwright-cli.json` by default so that yo
472478
| `PLAYWRIGHT_MCP_USER_AGENT` specify user agent string |
473479
| `PLAYWRIGHT_MCP_USER_DATA_DIR` path to the user data directory. If not specified, a temporary directory will be created. |
474480
| `PLAYWRIGHT_MCP_VIEWPORT_SIZE` specify browser viewport size in pixels, for example "1280x720" |
481+
</details>

package-lock.json

Lines changed: 13 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"devDependencies": {
3-
"@playwright/cli": "^0.0.63"
3+
"@playwright/cli": "^0.0.64"
44
}
55
}

scripts/update.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ async function main() {
1818
console.log(`Installed @playwright/cli version: ${version}`);
1919

2020
// 2. Run playwright-cli install-skills
21-
console.log('\n=== Running playwright-cli install-skills ===\n');
22-
run('npx playwright-cli install-skills');
21+
console.log('\n=== Running playwright-cli install --skills ===\n');
22+
run('npx playwright-cli install --skills');
2323

2424
// 3. Move generated skills into the existing skills folder
2525
console.log('\n=== Updating skills folder ===\n');

skills/playwright-cli/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,8 @@ playwright-cli video-stop video.webm
153153
### Install
154154
155155
```bash
156+
playwright-cli install --skills
156157
playwright-cli install-browser
157-
playwright-cli install-skills
158158
```
159159
160160
### Configuration

0 commit comments

Comments
 (0)