mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-24 10:37:54 -06:00
refactor: fold destinations with one rule
comparable_destination moves to core.paths. Placed, placement_block, the shared group merge of model.platforms and LauncherPlace.fold read it in place of their own lower(). It also trims surrounding blanks and slashes and folds with casefold: no destination, collection path or launcher name differs under those rules today, so the output is the same.
This commit is contained in:
1 parent
ca3ff1d4c5
commit
1c978f3083
7 files changed
+27
-23
No files matched your search
@@ -9,7 +9,7 @@ try:
|
||||
except ImportError:
|
||||
yaml = None
|
||||
|
||||
from core.paths import PLATFORMS_DIR
|
||||
from core.paths import PLATFORMS_DIR, comparable_destination
|
||||
from model.sources import source_yaml
|
||||
|
||||
|
||||
@@ -89,7 +89,7 @@ def _apply_shared_groups(config: dict, shared_groups: dict) -> None:
|
||||
# Lakka and RetroPie run on Linux, and np2kai opens 2608_bd.wav beside
|
||||
# System.dat's 2608_BD.WAV.
|
||||
def fold(destination: str) -> str:
|
||||
return destination.lower() if config.get("case_insensitive_fs") else destination
|
||||
return comparable_destination(destination, bool(config.get("case_insensitive_fs")))
|
||||
|
||||
for system in config.get("systems", {}).values():
|
||||
for group_name in system.get("includes", []):
|
||||
|
||||
Reference in new issue
Block a user