import { writeFileSync } from 'node:fs'; import { createRequire } from 'node:module'; import { resolve } from 'node:path'; const astroReq = createRequire(import.meta.resolve('astro')); const sharp = astroReq('sharp'); const ogSvg = ` v0.2.11 · Apache-2.0 · Zero Telemetry A macOS virtual machine for Windows 10 & 11 Metal to Vulkan 1.3 discrete GPU acceleration. Single EXE workbench, zero-CLI setup, Guest Tools v8. Metal → Vulkan 1.3 macOS Tahoe 26 GUI + CLI Single EXE Reims-Go 09:41 reims-graphics-pci · Vulkan 1.3 `; const outPath = resolve(process.cwd(), 'public/og-image.png'); const pngBuffer = await sharp(Buffer.from(ogSvg)).png({ compressionLevel: 9 }).toBuffer(); writeFileSync(outPath, pngBuffer); console.log(`Generated ${outPath} (${pngBuffer.length} bytes)`);