mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-06-28 21:46:13 +02:00
Add support for folder base journal.
Adds feature for issue #170 (and #398) where you configure your journal to be a directory and entries are added as sub-directories and files: yyyy/mm/dd.txt. Multiple entries in a day will go in the same file, but a new entry for a specific day will create a new file (and directory structure). Fix failed test scenarios for folder journal.
This commit is contained in:
parent
a3afa112ab
commit
a3c81d46fe
5 changed files with 138 additions and 5 deletions
|
@ -378,12 +378,9 @@ def open_journal(name, config, legacy=False):
|
|||
|
||||
return DayOneJournal.DayOne(**config).open()
|
||||
else:
|
||||
print(
|
||||
f"[Error: {config['journal']} is a directory, but doesn't seem to be a DayOne journal either.",
|
||||
file=sys.stderr,
|
||||
)
|
||||
from . import FolderJournal
|
||||
|
||||
sys.exit(1)
|
||||
return FolderJournal.Folder(**config).open()
|
||||
|
||||
if not config["encrypt"]:
|
||||
if legacy:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue