🔧 fix: generate .nojekyll instead of hand-editing generated files
The previous commit appended the .nojekyll rationale to docs/vendor/README.md — a file whose own first line reads "Generated by npm run build:docs. Do not edit by hand." CI's "Landing page bundle is in sync with src/" step regenerated it, the text vanished, git diff was non-empty and all three Node jobs failed. The guard did its job; I was the one who put a hand-written paragraph in a generated file. The note now lives in the generator, and build:docs writes docs/.nojekyll itself so it is part of the generated set rather than a loose file that a docs/ rewrite could drop. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SAcqrz3FcadkYr3xG32CjK
This commit is contained in:
@@ -73,9 +73,16 @@ await writeFile(
|
||||
`- \`babel.min.js\` — @babel/standalone ${JSON.parse(await readFile(path.join(root, 'node_modules/@babel/standalone/package.json'), 'utf8')).version}, ` +
|
||||
`used by the playground to compile TypeScript with standard decorators in the browser. ` +
|
||||
`Vendored rather than loaded from a CDN: the previous page referenced an unpinned unpkg URL, ` +
|
||||
`which silently began serving Babel 8 and broke the playground.\n`
|
||||
`which silently began serving Babel 8 and broke the playground.\n\n` +
|
||||
`- \`../.nojekyll\` — opts the directory out of Jekyll, so GitHub Pages serves it verbatim. ` +
|
||||
`Jekyll ignores paths beginning with an underscore and carries default \`vendor/\` exclusions, ` +
|
||||
`and the failure mode is an asset that silently does not publish — for this page, the ` +
|
||||
`playground's compiler 404ing while everything else looks fine.\n`
|
||||
);
|
||||
|
||||
// 5. Written rather than committed by hand so it cannot be lost in a docs/ rewrite.
|
||||
await writeFile(path.join(docs, '.nojekyll'), '');
|
||||
|
||||
console.log(`docs/cereale.js ${await size(path.join(docs, 'cereale.js'))}`);
|
||||
console.log(`docs/meta.js ${await size(path.join(docs, 'meta.js'))} (v${pkg.version})`);
|
||||
console.log(`docs/vendor/babel.min.js ${await size(path.join(vendor, 'babel.min.js'))}`);
|
||||
|
||||
Reference in New Issue
Block a user