From 8604d34521be2576ccc887d7799d0373da412720 Mon Sep 17 00:00:00 2001 From: Rob Golding Date: Tue, 5 Nov 2013 17:45:20 +0000 Subject: [PATCH] Only create the data directory if we're asked to --- tasklib/task.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasklib/task.py b/tasklib/task.py index 0546e44..c267048 100644 --- a/tasklib/task.py +++ b/tasklib/task.py @@ -230,7 +230,7 @@ class TaskQuerySet(object): class TaskWarrior(object): def __init__(self, data_location='~/.task', create=True): data_location = os.path.expanduser(data_location) - if not os.path.exists(data_location): + if create and not os.path.exists(data_location): os.makedirs(data_location) self.config = { 'data.location': os.path.expanduser(data_location), -- 2.39.5