236 Commits

Author SHA1 Message Date
46269dd94a Implementing controlling of the sorting order
The dialog looks quite ugly right now, but at least everything works. I
can work on making it prettier after this.
2020-08-14 19:17:38 +02:00
01f1b8481f Add scaffolding for an inline tag processor
This is just a simple test to extract the inline tags, it hasn't been
hooked up to anything.

Related to #44
2020-08-11 13:58:52 +02:00
7b1e328c7e Note: Always flush the file when writing
This may fix some edge cases where the notes aren't being saved.
2020-08-10 23:49:13 +02:00
bf0c9d1dfd Support piped wikilinks
Fixes #203
2020-08-10 21:10:55 +02:00
17dff46660 Remove wikilink duplicate regexp 2020-08-10 20:31:46 +02:00
9c01b8a931 NoteSerializer: Avoid using Settings.instance 2020-08-09 01:50:52 +02:00
633d9f5744 Remove more instances of Settings.instance
Use the Provider
2020-08-09 01:50:36 +02:00
619023660f NoteMetaData: Allow tags key to be configured
Fixes #206
2020-08-06 10:55:41 +02:00
c5deb3e988 Allow the 'created' YAML metadata to be configured
Related to #206
2020-08-03 00:46:41 +02:00
120e516ff9 SortingMode: Make public strings translatable 2020-07-31 21:45:08 +02:00
9374c35901 Note's title is no longer part of the metadata
So even if the YAML metadata is disabled, the title can be set.
2020-07-29 16:05:21 +02:00
4a97d03bd8 Title Codec: Support empty starting lines in the body 2020-07-29 15:25:17 +02:00
417f0414f2 Setting: Note metadata change subtitle 2020-07-29 15:13:37 +02:00
41447027f2 Allow 'title' saving to be configured
We now allow it be to either saved as the H1 or in the YAML metadata.
I'm not sure what the default should be. Still deciding.

Fixes #112
2020-07-28 17:26:42 +02:00
9ca19077e7 Remove invalid assert
Not sure why I put this assert, it doesn't seem to make sense.
2020-07-27 10:03:25 +02:00
6d101ad5c4 Remove flutter crashlytics
Sentry is being used instead, and it's working out quite well.
2020-07-26 19:05:52 +02:00
9d00fdac06 Use import_sorter
flutter pub run import_sorter:main --no-comments

The code feels much cleaner
2020-07-24 12:43:28 +02:00
b14e094e59 Copy Note to clipboard when it cannot be saved
Also avoid showing the actual exception. It's not very useful to the
user, and we're logging the exception to Sentry anyway.

Related to #124
2020-07-13 17:27:39 +02:00
fb9b69bb46 TagsFolder: Auto add relevant tag to new notes 2020-07-09 18:03:06 +02:00
309917d165 Move links parsing from the markdown string to another thread
This can be very expensive and the UI hands for a large number of notes,
otherwise.
2020-07-09 11:09:03 +02:00
ad535f3be7 Note Links: Considering anything which doesn't have a '://' as local
Only local notes are shown in the backlinks. Earlier our idea of local
links was notes which start with './', but now since we accept the
direct filename as well, we should support that in the backlinks as
well.
2020-07-08 00:49:45 +02:00
5e557ef6c3 Rename MetaLinkSyntax to WikiLinkSyntax 2020-06-12 13:50:54 +02:00
ae74e02fa7 Rename Note: Ensure markdown files end with .md
This broke when supporting txt files
2020-06-10 15:16:14 +02:00
b3014d4186 Log GitPush/Pull fails as errors
Instead of debug
2020-06-10 13:28:35 +02:00
97812e1501 Convert more prints to logs
This way they will show up in the LogViewer
2020-06-10 13:25:22 +02:00
51ececd150 Immediately save the note when changing
Earlier we would wait till we got the 'mutex' to make a change, however
with the way libgit2 works, during a git push/pull other git operations
such as add/rm/commit block.

So performing a save, while the push/pull is occuring - might have
resulted in a note being lost

Related to #124
2020-06-10 13:03:28 +02:00
267ecb7499 Implement a very basic file system view
This will show all the files and not just the "notes". This way the user
can easily figure out why a file isn't included in the list of notes.

It's currently disabled by default as it clearly needs a lot more work.
2020-06-10 00:54:15 +02:00
9ba0bc831c Catch possible exceptions when creating the fileName
This can apparently happen, and we should have a fallback. Additionally
Dart has both an 'Error' and an 'Exception' which are two different
things. This makes no sense.
2020-06-09 18:09:17 +02:00
67c2777d9b Parse links in wiki syntax [[term]]
This way we can use this faster syntax which is also supported by
Obsidian.
2020-06-08 00:52:03 +02:00
702366671a Move Link to its own file 2020-06-08 00:35:55 +02:00
e6be9aa228 Ensure new notes always have a proper file ending 2020-06-06 12:31:24 +02:00
7d9cd6e63a DocLoader: Ensure the isolate has been properly started
It seems that sometimes _sendPort is null. I'm not sure why. In those
cases lets try to reinitialize the isolate.

Fixes APP-2W
2020-06-04 15:46:51 +02:00
e0815c664d FlattenedNotesFolder: Always remove the note if present
In the FlattenedNotesFolder we can have a filter to only show certain
notes. This is used for showing notes that match some tags. When the
note is added to this virtual folder it matches the tag, but later it
does not.
2020-06-04 14:21:58 +02:00
2dbc2dda77 Add support for filenames based on Uuid 2020-06-04 02:12:13 +02:00
42d6386096 Add basic txt file support
With this 'txt' files are now read and written. However, they don't have
any metadata so they don't show up correctly in the sort order and
currently the Markdown Editor is still available for them.

Related to #55
2020-06-02 00:15:18 +02:00
fb5ab57fe0 Folder.removeFolder: Remove listeners recursively
Ideally when removing a folder one shouldn't have any notes, but
sometimes we do allow an entire folder to be reset.

Related to #36
2020-05-31 03:38:24 +02:00
5788a2bde0 FlattenedNotesFolder: Propogate renames 2020-05-31 03:08:49 +02:00
b9b53f28c4 Log some exceptions are warnings
These aren't really a problem, but it's still interesting to know if
they are happening.
2020-05-31 02:00:00 +02:00
d665981182 Allow Git remote host to be reset
This is quick and dirty way of fixing the problem. It doesn't migrate
the notes from the previous repo and just discards them, so you cannot
move your notes from one repo to another using GitJournal (for now), but
at least its better than having to re-install the app.

Related to #36
2020-05-26 23:53:14 +02:00
18c93fbbb4 Note: Do not change the body if it hasn't been modified
I'm scared that for very large notes this won't be very fast, on the
other hand changing the body results in many other fields being
re-computed.
2020-05-26 18:07:24 +02:00
d3fb2b7119 Try to make the backlinks section prettier
I'm not totally convinced that it should be here.
2020-05-26 18:05:50 +02:00
4eeff093c1 Cache the Links in a note
This requires the markdown to be parsed which can be an incredibly slow
operation, so lets avoid re-doing it unless necessary.
2020-05-26 17:08:03 +02:00
96ed70f023 Show the backlinks of a Note
This is the initial proof of concept and doesn't look very pretty. It's
also not very efficient.

Related to #141
2020-05-26 15:37:09 +02:00
af69dd6e48 Note: Allow returning the links in the document
This isn't perfect as we aren't handling referenced links and maybe even
autolinks, but it's a start.

Related to #141
2020-05-26 14:50:23 +02:00
bcbf54106f Handle empty checklists
If there were no items we were ignoring the checklist. Added some extra
tests as well.

Fixes #148
2020-05-26 13:43:41 +02:00
4c56ddc4df Allow the default Image location to be configured
Fixes #10
2020-05-20 00:32:13 +02:00
26ed82fdbc Make "Root Folder" translatable
It was earlier duplicated all over the place.
2020-05-18 00:26:00 +02:00
816cb0c3ed Reduce code duplication
Avoid code for determining the publicName of a folder.
2020-05-18 00:23:14 +02:00
f4ad226341 NoteFileName Format: Move it to Folder Settings
This way each folder can have its own default file naming scheme.
2020-05-18 00:13:20 +02:00
a324d0f755 Logging: Allow logging structured fields
Display this in the Debug Screen app. Additionally, add a reason why a
file was not loaded.
2020-05-17 19:47:11 +02:00