README.md and CONTRIBUTING.md open with a comment naming their generator, generate_readme.py --check fails on a hand edit in validate.yml and pr_checks.py, and .gitattributes marks the pipeline outputs as generated, held equal to core/generated.py by a test. _mame_clones.json becomes mame_clones.json, still written beside the scanned bios/ tree, and now triggers both workflows (coverage reads it). docs_assets/ moves to website/assets/, which Astro does not read as content. ACCESSIBILITY.md becomes wiki/accessibility.md, linked from the README and the installer page. The screenshot list moves to wiki/images-wanted.md: nothing read docs_assets/screens/. The architecture map names every root entry (test_repository_map), platforms/README.md keeps only what this folder holds, the reference index lists archive-recipes and measurements, and reference-terms no longer defines Profile twice nor repeats the glossary's Pack.
Platform configs
What each file of this folder holds. How a platform checks its files is in How each platform checks files, and the steps to add one are in Adding a platform.
Files
<platform>.yml: the platform's own BIOS list, written by its scraper (scripts/scraper/<platform>_scraper.py). A hand edit is overwritten by the next scrape: the fix goes in the scraper,_shared.ymlor a profile.lakka.ymlandretropie.ymlinheritretroarch,romm.ymlinheritsemulatorjs._registry.yml: platform metadata (name, scraper, release pack, install detection, display order)._shared.yml: file groups several platforms include, with the destination the core expects._data_dirs.yml: whole directory trees a core needs._guides.yml: the guide text of each platform's page on the site._core_info.json: the git blob of every libretro.infoas last reviewed, written bycheck_freshness.py --record-coreinfo.targets/: the cores each hardware target runs, one file per platform.romfolders/: the rom folders of each setup.
Shared groups (_shared.yml)
The subdirectory a BIOS goes into is set by the core, not the platform.
NP2kai expects np2kai/BIOS.ROM on RetroArch, Batocera and Recalbox alike.
Only base_destination varies (system/ or bios/).
A group declares those files and their destination once, and platforms
include it with includes: [group_name] in a system. load_platform_config()
(scripts/model/platforms.py) resolves the includes at load time. A scraper
that writes a platform keeps its includes in its own SYSTEM_SHARED_GROUPS,
so they survive the next scrape. libretro_scraper.py also prefixes the
subdirectory of the cores in CORE_SUBDIR_MAP.
Adding a group:
- Add it to
_shared.ymlwith a comment citing the code that reads the path. - Give each file its name, destination with the subdirectory,
requiredand hashes. - Reference it with
includes: [group_name], in the scraper'sSYSTEM_SHARED_GROUPSfor a scraped platform.
Where the subdirectories come from:
| Core | Subdirectory | Source |
|---|---|---|
| NP2kai | np2kai/ |
libretro-np2kai/sdl/libretro.c |
| PX68k | keropi/ |
px68k/libretro/libretro.c |
| QUASI88 | quasi88/ |
quasi88/src/libretro.c |
| Kronos | kronos/ |
libretro-kronos/libretro/libretro.c |
| ep128emu | ep128emu/roms/ |
ep128emu-core/src/libretro.cpp |
| Flycast | dc/ |
flycast/shell/libretro/libretro.cpp |
| FBNeo NeoCD | neocd/ |
fbneo/src/burn/drv/neogeo/neo_run.cpp |
| Fuse | fuse/ |
fuse-libretro/fuse/settings.c |
| hatari | hatari/tos/ |
hatari/src/tos.c |
Data directories (_data_dirs.yml)
Some cores need a whole tree: Dolphin's dolphin-emu/Sys/, PPSSPP's assets,
blueMSX's Databases/ and Machines/. Each entry names its upstream source.
scripts/refresh_data_dirs.py fetches them into data/, which is not indexed
in database.json, and pack generation refreshes them first unless
--offline is given.
Adding a data directory:
- Add the entry with its source URL, extraction path and cache location.
- Reference it with
data_directories: [{ref: key, destination: path}]in a platform system, in the scraper'sSYSTEM_DATA_DIRSfor a scraped platform. - Run
python scripts/refresh_data_dirs.py --key <name>to fill the cache.
Targets (targets/)
<platform>.yml lists the cores of each hardware target, written by the
platform's target scraper (scripts/scraper/targets/), or kept by hand for a
single-target platform. _overrides.yml is never overwritten: it adds
aliases and adds or removes cores per target, _default for every target.
Rom folders (romfolders/)
_sources/<setup>.yml names the repositories and commits to read and the
facts a parser cannot read from a table. python -m scripts.scraper.romfolders
writes <setup>.yml from them, with the folder names the OS itself uses.