File tree 3 files changed +20
-3
lines changed
3 files changed +20
-3
lines changed Original file line number Diff line number Diff line change @@ -6,9 +6,9 @@ Playwright is a Python library to automate [Chromium](https://www.chromium.org/H
6
6
7
7
| | Linux | macOS | Windows |
8
8
| :--- | :---: | :---: | :---: |
9
- | Chromium <!-- GEN:chromium-version --> 86 .0.4238 .0<!-- GEN:stop --> | ✅ | ✅ | ✅ |
10
- | WebKit 14.0 | ✅ | ✅ | ✅ |
11
- | Firefox <!-- GEN:firefox-version --> 80.0b8 <!-- GEN:stop --> | ✅ | ✅ | ✅ |
9
+ | Chromium <!-- GEN:chromium-version --> 88 .0.4324 .0<!-- GEN:stop --> | ✅ | ✅ | ✅ |
10
+ | WebKit <!-- GEN:webkit-version --> 14.0<!-- GEN:stop --> | ✅ | ✅ | ✅ |
11
+ | Firefox <!-- GEN:firefox-version --> 83.0 <!-- GEN:stop --> | ✅ | ✅ | ✅ |
12
12
13
13
Headless execution is supported for all browsers on all platforms.
14
14
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
3
+ python scripts/update_versions.py
4
+
3
5
function update_api {
4
6
echo " Generating $1 "
5
7
file_name=" $1 "
Original file line number Diff line number Diff line change
1
+ import re
2
+ from playwright import sync_playwright
3
+
4
+ with sync_playwright () as p :
5
+ r = open ("README.md" , "r" )
6
+ text = r .read ()
7
+ for browser_type in [p .chromium , p .firefox , p .webkit ]:
8
+ rx = re .compile (r"<!-- GEN:" + browser_type .name + r"-version -->([^<]+)<!-- GEN:stop -->" )
9
+ browser = browser_type .launch ()
10
+ text = rx .sub (f"<!-- GEN:{ browser_type .name } -version -->{ browser .version } <!-- GEN:stop -->" , text )
11
+ browser .close ()
12
+
13
+ w = open ("README.md" , "w" )
14
+ w .write (text )
15
+ w .close ()
You can’t perform that action at this time.
0 commit comments