summaryrefslogtreecommitdiff
path: root/lib/utils/paths.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/utils/paths.py')
-rwxr-xr-xlib/utils/paths.py4
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: