-
Notifications
You must be signed in to change notification settings - Fork 203
/
postprocess.ts
33 lines (22 loc) · 984 Bytes
/
postprocess.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
const apt_install = Deno.run({
cmd: ['sudo', 'apt-get', 'install', "libegl1", "libopus0", "libwoff1", "libharfbuzz-icu0", "gstreamer1.0-plugins-base", "libgstreamer-gl1.0-0", "gstreamer1.0-plugins-bad", "libopenjp2-7", "libwebpdemux2", "libenchant1c2a", "libhyphen0", "libgles2", "gstreamer1.0-libav", "libevdev-dev"],
});
await apt_install.status();
// install requirements with pip
const pip_install = Deno.run({
cmd: ['python', '-m', 'pip', 'install', '-r', 'requirements.txt'],
});
await pip_install.status();
const playwright_install = Deno.run({
cmd: ['python', '-m', 'playwright', 'install'],
});
await playwright_install.status();
const playwright_configure = Deno.run({
cmd: ['sudo', 'npx', 'playwright', 'install-deps'],
});
await playwright_configure.status();
// Forwards the execution to the python script
const py_run = Deno.run({
cmd: ['python', './postprocessing.py'].concat(Deno.args),
});
await py_run.status();