diff --git a/jrnl/EncryptedJournal.py b/jrnl/EncryptedJournal.py index fe0716cb..3dae48e1 100644 --- a/jrnl/EncryptedJournal.py +++ b/jrnl/EncryptedJournal.py @@ -43,8 +43,8 @@ class EncryptedJournal(Journal): dirname = os.path.dirname(filename) if not os.path.exists(filename): if not os.path.isdir(dirname): - os.mkdir(dirname) - print(f"[Directory {dirname} created]") + os.makedirs(dirname) + print(f"[Directory {dirname} created]",file=sys.stderr) self.create_file(filename) self.password = util.create_password(self.name) print( diff --git a/jrnl/Journal.py b/jrnl/Journal.py index 3589fbdd..8b257eb9 100644 --- a/jrnl/Journal.py +++ b/jrnl/Journal.py @@ -77,8 +77,8 @@ class Journal: dirname = os.path.dirname(filename) if not os.path.exists(filename): if not os.path.isdir(dirname): - os.mkdir(dirname) - print(f"[Directory {dirname} created]") + os.makedirs(dirname) + print(f"[Directory {dirname} created]",file=sys.stderr) self.create_file(filename) print(f"[Journal '{self.name}' created at {filename}]", file=sys.stderr)