This is supposed to create a zip of all the files in the repo, and its
.git folder. It's super useful for debugging the state of the repo, and
it's also useful when the remote is down but you still have changes
which you want to export.
Instead we're going to move back to standard exceptions.
Using a custom Result class has created far far more problems
- The Stacktraces aren't always right
- Sometimes one forgets to check the Result error
- All other exception throwing code needing to be converted to Results
- Non idiomatic Dart code
I think it's better to just go back to exceptions. They have their
problems, but overall, I think it's a better approach.
Not everywhere, but a large part of the code base.
This way, hot reloading will also reload the strings which makes for
such a better developer experience.
Any files with external contributions need to be Apache2 licensed, since
I don't have any CLA, and need to release this on the ios store where
*GPL apps are a problem.
This allows switching the precision of Unix timestamps in YAML
frontmatter between second (the current beahaviour) and millisecond
(compatible with Dendron) precision.
This way the disk barely needs to be accessed when loading GitJournal,
and we can hide how long it takes GitJournal to parse all the notes in
the background.
Fixes#78
This is probably the largest commit that I have ever made. From now on -
every File always has an mtime and ctime which is fetched from git.
Notes can optionally override that time by providing yaml metadata.
Additionally the 'filePath' and 'folderPath' is now relative to the
repoPath instead of being the full path.
This will slow down GitJournal like crazy as all the mtimes and ctime
still need to be cached. For my test repo it takes about 23 seconds for
GitJournal to become responsive.
If we let the space be optional then this picks up bold/italics as well.
Ideally, the stripMarkdown formatting could be made smarter, but I would
prefer to just rid of it in the future, and use the proper markdown
parser.
The only thing that is stopping me right now is performance. So in the
future when the stripped version is cached, this should be fine.
Fixes#420
Platform from dart:io cannot be used on the web for reasons. And this
way we get a fake File/Directory class which we can use for atleast
running the web version, even if it won't work.