mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-10-27 22:27:21 -05:00
feat: build the site with Astro Starlight
generate_site.py writes the Starlight project in website/ and nothing else: mkdocs.yml, the MkDocs hooks, theme overrides and stylesheet go, and the wiki is written in Starlight's syntax. Both workflows set up Node with the official actions/setup-node pinned by commit, run npm ci from the committed lockfile, build with the strict link validator and check the result with validate_site.py. The search weighs a page by what it answers: Start here pages first, a system page's cards and file names before a guide citing them, deep guides, launchers, aliases and frozen copies after. Status badges, hash blocks and the export change lists leave the index. The ranking sits at the centre of a range where the 13 queries of search_gate.py all answer, in the search box itself. 839 pages, every URL and 45,611 ids match the MkDocs build. The tests read the Starlight content and syntax.
This commit is contained in:
1 parent
abe240073c
commit
123d698e43
64 files changed
+742
-3118
No files matched your search
@@ -66,12 +66,21 @@ export default defineConfig({
|
||||
expressiveCode: { defaultProps: { wrap: true } },
|
||||
lastUpdated: false,
|
||||
pagination: true,
|
||||
// Measured on the ten queries of tools/search_gate.py, inside a range
|
||||
// where all ten answer: Starlight's defaults (0.1, 0.1, 2, 9) let a guide
|
||||
// that cites scph5501 once outrank the file's own card. A long page
|
||||
// is penalised a little more, and how often a word appears counts.
|
||||
// Measured on the queries of tools/search_gate.py, at the centre of a
|
||||
// range where all of them answer. How often a word appears counts more
|
||||
// than in Starlight's defaults (0.1, 0.1, 2, 9), a page's title weighs
|
||||
// ten times its text, so "dolphin" finds Dolphin, and the file names of
|
||||
// a system page (its `files` field, written by sitestarlight.py) count
|
||||
// half, so "scph5501" finds the Sony page without a file name winning
|
||||
// every other query.
|
||||
pagefind: {
|
||||
ranking: { pageLength: 0.3, termFrequency: 0.5, termSaturation: 1.4, termSimilarity: 9 },
|
||||
ranking: {
|
||||
pageLength: 0.1,
|
||||
termFrequency: 0.5,
|
||||
termSaturation: 1.4,
|
||||
termSimilarity: 9,
|
||||
metaWeights: { title: 10, files: 0.5 },
|
||||
},
|
||||
},
|
||||
plugins: [
|
||||
starlightSidebarTopics(sidebar.topics, sidebar.options),
|
||||
|
||||
Reference in new issue
Block a user