davsclaus opened a new pull request, #1769: URL: https://github.com/apache/camel-website/pull/1769
Fixes #1762. ## What changed - `gulp/tasks/generate-markdown.js` no longer ignores every `index.html`. An `index.html` is converted when it is a content page (has an `article.doc`, which is what the Hugo `static doc` layouts and Antora emit); list and section pages that only have a `<main>` (home, download, community, projects, docs, tooling lists) are skipped, so nothing turns a card grid into Markdown. Blog posts (`public/blog/**/index.html`) are excluded on purpose, see #1763, and `public/releases/**/index.html` because `generateAllIndexes` already converts those. - The mirror is published as `<page>/index.md` next to the page, e.g. `https://camel.apache.org/what-is-apache-camel/index.md`. I chose this over `/what-is-apache-camel.md` because the page's relative links (`../components/next/`, `../manual/getting-started.md`) only resolve from the same directory, and it is the path the release pages and the blog RSS index already use. - The embedded table of contents of the `single.html` layout (`aside.toc`, which left a stray `### Contents` heading) is dropped from the Markdown. - `llms-txt-template.md` documents the rule (append `index.md` to a URL ending in `/`), renames "What is Apache Camel" to "Start here", and links *What is Apache Camel*, *When to use*, *Why Apache Camel* (trust) and *Camel DNA* as Markdown; *Who uses Apache Camel* likewise. - Tests: a Hugo content page converts without its TOC; a page with only a `<main>` converts by default but is skipped with `articleOnly`. ## Side effect worth knowing The blanket ignore was also skipping the Antora pages rendered as `index.html` — `camel-core/getting-started/index.html` (21 KB), `camel-core/contributing/index.html`, `components/4.22.x/index.html` and the like. Those get a `.md` now too (54 files). ## Verification - `yarn test`: 14 pass. - Full `yarn build` from the root: exit 0, no errors, 5598 Markdown files. Checked `what-is-apache-camel`, `when-to-use`, `trust`, `camel-dna`, `community/team`, `community/user-stories` get an `index.md`; `download/`, `community/`, the home page do not; no `### Contents` leaks. Note: touches `llms-txt-template.md` in different sections than #1768, so the two should merge cleanly in either order. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
