mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-10-24 04:39:06 -05:00
The script exporters (Batocera, ROCKNIX, KNULLI, AmberELEC, EmuELEC) read the checker of the pinned original: when checkBios hands an item's md5 to a function that tests it with isinstance(..., list), as md5Matches does since batocera.linux 6b08b873, an entry whose emulator code accepts several dumps is written with all of them, and an addition that needed several becomes writable. Items with altmd5 keep a string, since checkBios wraps them in a list of its own. No cached original reads lists today, so every export is unchanged. The report records a list as a list, counts the lists written, and records a list the truth extends without contradicting it.
44 lines
1.3 KiB
Python
44 lines
1.3 KiB
Python
"""Exporter for AmberELEC's batocera-systems.
|
|
|
|
Batocera's script shape, so only the systems dict is rewritten. Two things
|
|
differ. Paths are relative to /storage/roms, where the list also names
|
|
neogeo/ beside bios/, and our destinations start there too. No entry carries
|
|
an emulator or core gate: coreExists() lets an ungated item through for
|
|
every build, and an addition is written the same way.
|
|
"""
|
|
|
|
from __future__ import annotations
|
|
|
|
from .baseline import NativeFile
|
|
from .batocera_exporter import Exporter as BatoceraExporter
|
|
|
|
SOURCE_URL = (
|
|
"https://raw.githubusercontent.com/AmberELEC/AmberELEC/dev"
|
|
"/packages/amberelec/sources/scripts/batocera-systems"
|
|
)
|
|
|
|
|
|
class Exporter(BatoceraExporter):
|
|
"""Write AmberELEC's batocera-systems, corrected."""
|
|
|
|
PATH_PREFIX = ""
|
|
|
|
# The list gates nothing on a runner, so an addition needs none.
|
|
RUNNER_GATED = False
|
|
|
|
def _addition_keys(self, fe: NativeFile) -> list[tuple[str, str | None]] | None:
|
|
return []
|
|
|
|
@staticmethod
|
|
def platform_name() -> str:
|
|
return "amberelec"
|
|
|
|
@staticmethod
|
|
def file_modes() -> dict[str, int]:
|
|
# 100755 at a21975bf (git/trees).
|
|
return {"batocera-systems": 0o755}
|
|
|
|
@staticmethod
|
|
def native_sources() -> dict[str, str]:
|
|
return {"batocera-systems": SOURCE_URL}
|