From 477f1e6ca38285fabfb0e9c316dde2ee452b3bb1 Mon Sep 17 00:00:00 2001 From: Aphelion <61633628+AphelionWasTaken@users.noreply.github.com> Date: Sat, 8 Mar 2025 06:10:31 -0600 Subject: [PATCH] Get path on Unix --- .github/workflows/build.yml | 8 +++++--- PySN.py | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1e23c24..f1d8ae4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -103,10 +103,12 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: - tag_name: v2.1.8 - release_name: Release v2.1.8 + tag_name: v2.1.9 + release_name: v2.1.9 body: | - Build MacOS Executable. + Correctly get the path to PySN on unix systems. + + This fixes updates not saving in the correct default locations on MacOS and Linux. draft: false prerelease: false diff --git a/PySN.py b/PySN.py index 29f6d16..6d31729 100644 --- a/PySN.py +++ b/PySN.py @@ -72,7 +72,7 @@ def save_config(mode, save_dir , rpcs3_dir): #Checks for the config file, and gets the settings from it. Saves default config if none present. def check_config(): - normalized_path = os.getcwd().replace('\\','/') + normalized_path = os.path.dirname(__file__).replace('\\','/') config_path = (normalized_path + '/config.ini') if path.exists(config_path): save_dir, rpcs3_dir = ConfigSettings.get_config()