diff --git a/.gitignore b/.gitignore index d36353ff..52b48ef5 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,7 @@ coverage _lib node_modules +create-farc/templates tsconfig.*.tsbuildinfo tsconfig.tsbuildinfo .vercel diff --git a/.scripts/postbuild.ts b/.scripts/postbuild.ts index e924b613..a5d8e32b 100644 --- a/.scripts/postbuild.ts +++ b/.scripts/postbuild.ts @@ -1,7 +1,9 @@ import { dirname, relative, resolve } from 'node:path' import glob from 'fast-glob' +import { copy } from 'fs-extra' await rewriteHonoJsx() +copyTemplates() async function rewriteHonoJsx() { const files = await glob('./src/_lib/**/*.js') @@ -25,3 +27,10 @@ async function rewriteHonoJsx() { ) } } + +function copyTemplates() { + copy( + resolve(import.meta.dirname, '../templates'), + resolve(import.meta.dirname, '../create-farc/templates'), + ) +}