From 594c506dc703090a8bbd5edc616af643cabcc140 Mon Sep 17 00:00:00 2001 From: HRiggs Date: Fri, 12 Jun 2026 22:07:38 -0400 Subject: [PATCH] fix: pathing --- progression_tui.py | 7 ++++--- steam_workshop_gui.py | 5 +++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/progression_tui.py b/progression_tui.py index 85a45dc..fa4f1d2 100644 --- a/progression_tui.py +++ b/progression_tui.py @@ -370,8 +370,9 @@ class ProgressionTUI: def derive_workshop_path(self): """Derive workshop path from RimWorld path""" - if "steamapps" in self.rimworld_path.lower(): - parts = self.rimworld_path.split(os.sep) + normalized_rimworld_path = os.path.normpath(self.rimworld_path) + if "steamapps" in normalized_rimworld_path.lower(): + parts = normalized_rimworld_path.split(os.sep) try: steamapps_index = next(i for i, part in enumerate(parts) if part.lower() == 'steamapps') workshop_parts = parts[:steamapps_index + 1] + ['workshop', 'content', '294100'] @@ -1157,4 +1158,4 @@ def main(): if __name__ == "__main__": - main() \ No newline at end of file + main() diff --git a/steam_workshop_gui.py b/steam_workshop_gui.py index f2b9221..ca8d006 100644 --- a/steam_workshop_gui.py +++ b/steam_workshop_gui.py @@ -2835,9 +2835,10 @@ class SteamWorkshopGUI: # From: D:\SteamLibrary\steamapps\common\RimWorld # To: D:\SteamLibrary\steamapps\workshop\content\294100 - if "steamapps" in rimworld_path.lower(): + normalized_rimworld_path = os.path.normpath(rimworld_path) + if "steamapps" in normalized_rimworld_path.lower(): # Find the steamapps part and replace common\RimWorld with workshop\content\294100 - parts = rimworld_path.split(os.sep) + parts = normalized_rimworld_path.split(os.sep) try: steamapps_index = next(i for i, part in enumerate(parts) if part.lower() == 'steamapps') # Build new path: everything up to steamapps + steamapps + workshop + content + 294100