/** * One-shot script: writes the canonical Plant_Hours_Template_2.xlsx * to RAW_DOCS/. Run when the template layout changes — keep the * seed file in sync with src/lib/plant-hours-template.ts. * * npx tsx scripts/generate-plant-hours-template.ts */ import * as fs from "node:fs"; import * as path from "node:path"; import { fileURLToPath } from "node:url"; import { buildPlantHoursTemplateWorkbook } from "../src/lib/plant-hours-template"; const here = path.dirname(fileURLToPath(import.meta.url)); const out = path.resolve(here, "../RAW_DOCS/Plant_Hours_Template_2.xlsx"); const bytes = buildPlantHoursTemplateWorkbook(); fs.writeFileSync(out, bytes); console.log(`Wrote ${out} (${bytes.byteLength} bytes)`);