diff options
| author | Kaalleen <36401965+kaalleen@users.noreply.github.com> | 2025-06-29 06:46:22 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-29 06:46:22 +0200 |
| commit | c7102e6cece6551f7d5a74f6e3350967fab1741d (patch) | |
| tree | c48236266703a7b92f1475c51e63e50c8652880c /lib/utils/paths.py | |
| parent | 0d461e3aef42b046b7ca14e2b0a05990306030d4 (diff) | |
| parent | 40f1b2eccfc27764e49b20bf712d4f5fa321fcac (diff) | |
Merge pull request #3826 from not-my-profile/fix-nix
Fix package build with Nix package manager
Diffstat (limited to 'lib/utils/paths.py')
| -rwxr-xr-x | lib/utils/paths.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/utils/paths.py b/lib/utils/paths.py index 3bc12c2a..542a0f2d 100755 --- a/lib/utils/paths.py +++ b/lib/utils/paths.py @@ -41,12 +41,12 @@ def get_resource_dir(name): return realpath(os.path.join(dirname(realpath(__file__)), '..', '..', name)) -def get_user_dir(name=None): +def get_user_dir(name=None, create=True): try: path = platformdirs.user_config_dir('inkstitch') except ImportError: path = os.path.expanduser('~/.inkstitch') - if not os.path.exists(path): + if create and not os.path.exists(path): os.makedirs(path) if name is not None: |
