feat: run the search gate before each deploy

This commit is contained in:
Abdessamad Derraz committed 2026-10-23 18:58:54 +02:00
1 parent e1d35c3cb4
commit a93e9ee406
3 files changed
+123 -15

No files matched your search

+9 -2
View File
@@ -2,10 +2,17 @@
// node measure.mjs weight <base url> <page>...
// node measure.mjs search <base url> starlight|mkdocs <query>...
// Transfer sizes are bytes on the wire (gzip from serve.mjs), by type.
import { chromium } from 'playwright-core';
// playwright-core is resolved from website/node_modules, above this file,
// wherever the command is run from. It is not a dependency of the build:
// npm install --no-save --prefix website playwright-core
const { chromium } = await import('playwright-core').catch((error) => {
console.error(`playwright-core is not in website/node_modules (${error.code}): `
+ 'npm install --no-save --prefix website playwright-core');
process.exit(2);
});
const [mode, base, ...rest] = process.argv.slice(2);
const browser = await chromium.launch({ executablePath: '/usr/bin/google-chrome' });
const browser = await chromium.launch({ executablePath: process.env.CHROME_PATH || '/usr/bin/google-chrome' });
const track = (page) => {
const rows = [];