Laverna / laverna

Laverna is a JavaScript note taking application with Markdown editor and encryption support. Consider it like open source alternative to Evernote.
https://laverna.cc/index.html
Mozilla Public License 2.0
9.19k stars 801 forks source link

Cross OS import/export bug - fs blocks Laverna #803

Open Kaleidosko opened 7 years ago

Kaleidosko commented 7 years ago

Hello everyone,

if you export the settings on a windows pc with enabled FS-Module (which by the way is really useful) and try to import them into a Laverna running on Linux, the Laverna window stays white. The error log shows a hint like "could not find path" and something with "mkdir". If you need further Information I will reproduce the error.

Greetings Kal

ghost commented 6 years ago

This problem isn't just isolated to cross-OS export/import. I just experienced the same issue trying to import settings from one Linux machine to another. The FS module hardcodes the directory one initially sets; if the directory doesn't exist on the new machine, everything pukes and hangs up.{

I was able to workaround this by manually editing laverna-settings.json. There is an object in the json file like follows:

{"name": "module:fs:folder", "value": "/some/directory", "updated": 1234, "created": 1234}

By changing the value field to the directory you want to use on the new machine before you import the settings, everything seems to work just fine.