mirror of
https://github.com/rommapp/romm.git
synced 2026-06-27 22:35:57 +00:00
lower fs name
This commit is contained in:
@@ -60,6 +60,10 @@ COMPRESSED_FILE_EXTENSIONS = frozenset(
|
||||
)
|
||||
)
|
||||
|
||||
# PICO-8 cartridges are often stored as PNG files
|
||||
PICO8_CARTRIDGE_EXTENSION = ".p8.png"
|
||||
|
||||
|
||||
# CHD (Compressed Hunks of Data) v5 format constants
|
||||
# See: https://github.com/mamedev/mame/blob/master/src/lib/util/chd.h
|
||||
CHD_SIGNATURE: Final = b"MComprHD"
|
||||
@@ -105,8 +109,6 @@ NON_HASHABLE_PLATFORMS = frozenset(
|
||||
|
||||
FILE_READ_CHUNK_SIZE = 1024 * 8
|
||||
|
||||
PICO8_CARTRIDGE_EXTENSION = ".p8.png"
|
||||
|
||||
|
||||
class FSRom(TypedDict):
|
||||
fs_name: str
|
||||
@@ -740,7 +742,9 @@ class FSRomsHandler(FSHandler):
|
||||
the cartridge label/cover art. When such a ROM is found we can use the
|
||||
file itself as the cover instead of fetching one from an external source.
|
||||
"""
|
||||
if platform_slug == UPS.PICO and fs_name.endswith(PICO8_CARTRIDGE_EXTENSION):
|
||||
if platform_slug == UPS.PICO and fs_name.lower().endswith(
|
||||
PICO8_CARTRIDGE_EXTENSION
|
||||
):
|
||||
rom_path = self.validate_path(f"{fs_path}/{fs_name}")
|
||||
return f"file://{rom_path}"
|
||||
return None
|
||||
|
||||
Reference in New Issue
Block a user