refactor: standardize hack filenames to [Hack] and flatten to platform root

Switch the library naming convention from "Pokemon - <Name> (Hack)" to
"Pokemon - <Name> [Hack][version][tags]", and place hacks in the platform
root (roms/<plat>/) instead of a Hacks/ subfolder. Applied across the live
valhalla library (272 hack/fan-game files) via scripts/standardize-names.py.

- romhack-import.py / romhack-fetch.py: emit [Hack], write to roms/<plat>/
- romhack-pc-migrate.py: emit [Hack]
- build-romhack-vault.py (archived): update documented library_path
- standardize-names.py: new one-shot, self-fetching standardizer (idempotent;
  pipes \n-only bytes over SSH to avoid Windows CRLF corrupting filenames)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
ginnoir
2026-06-23 18:08:31 -05:00
co-authored by Claude Opus 4.8
parent 52ee1b98a1
commit ae56d101b7
6 changed files with 112 additions and 19 deletions
+3 -3
View File
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
"""Acquire, patch, validate, and place worthwhile Pokémon ROM-hacks into the
EmuDeck library at /storage1/Emulation/roms/<platform>/Hacks/ on valhalla.
EmuDeck library at /storage1/Emulation/roms/<platform>/ on valhalla.
Each hack is one MANIFEST entry naming its source. Two source kinds:
- "rom": a pre-patched full ROM is downloaded and placed as-is (validated).
@@ -242,7 +242,7 @@ def main():
raise RuntimeError(f"validation: {verr}")
crc = zlib.crc32(open(src, "rb").read()) & 0xffffffff
if place:
dst_dir = os.path.join(ROMS, plat, "Hacks")
dst_dir = os.path.join(ROMS, plat)
os.makedirs(dst_dir, exist_ok=True)
shutil.copy2(src, os.path.join(dst_dir, out_name))
detail += " | PLACED"
@@ -253,7 +253,7 @@ def main():
for hk, pl, st, dt, nm in rows:
print(f"[{st:4}] {pl:4} {hk:<20} {dt}")
if st == "OK":
print(f" -> {pl}/Hacks/{nm}")
print(f" -> {pl}/{nm}")
print(f"\nplaced: {'YES (--place)' if place else 'NO (dry run; pass --place)'}")
if __name__ == "__main__":