mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-10-20 18:59:07 -05:00
fix: join system names with a separator they lack
This commit is contained in:
1 parent
e644463c17
commit
9c154a29b9
2 files changed
+19
-2
No files matched your search
@@ -258,9 +258,12 @@ def _bounded_join(parts: list[str], keys: list[str]) -> str:
|
||||
"""Parts joined while they fit, else the first, a count and a digest.
|
||||
|
||||
Thirty systems joined made a 261-byte file name and the ZIP could not
|
||||
be opened; the digest keeps two different selections apart.
|
||||
be opened; the digest keeps two different selections apart. The joiner
|
||||
is one no part holds: with "_", sega-dreamcast + arcade and
|
||||
sega-dreamcast-arcade both named Dreamcast_Arcade, and the second build
|
||||
replaced the first.
|
||||
"""
|
||||
joined = "_".join(parts)
|
||||
joined = "+".join(parts)
|
||||
if len(joined.encode("utf-8")) <= MAX_SYSTEM_TAG_BYTES:
|
||||
return joined
|
||||
digest = hashlib.sha1("\n".join(sorted(keys)).encode("utf-8")).hexdigest()[:8]
|
||||
|
||||
Reference in new issue
Block a user