dragotin / kraft

Kraft helps to handle your daily quotes and invoices in your small business.
http://volle-kraft-voraus.de
GNU General Public License v2.0
60 stars 19 forks source link

(branch newshared): The root path for document data should be configurable #243

Closed noseshimself closed 1 month ago

noseshimself commented 2 months ago

If you want to enable as many users to use their preferred cloud storage provider there should be a way to configure the path for "~/.local/share/kraft/v2/".

NextCloud is permitting me to sync multiple trees now but if Kraft is supposed to be storage-agnostic and work with GDrive and others that insist on syncing only one tree it should offer a configurable variable.

dragotin commented 2 months ago

Yes, it is configurable in $HOME/.config/kraftrc. There you find a section like this:

[KraftV2]
KraftV2BaseDir=/home/kf/.local/share/kraft/v2

The path can be changed manually. Note that it also uses that entry to check if it was already configured to V2 or not. Removing that entry in the config lets Kraft repeat the migration from V1->V2 into a new directory.

For now the recommendation would be to create the skeleton filetree in the default path, and copy the symlink called current and the directory which it points to to the new location and after that change the config value.

Please let me know if and how that worked for you.

dragotin commented 2 months ago

Ah of course, later there will be a UI-setting to change that path.

noseshimself commented 2 months ago

Working.

Would you mind adding this to the information provided in "About Kraft" just in case... "Kraft v2 database path: /my/cloud-dumpster/Kraft"

PS: I vandalized that release using WebDAV mounts to my cloud storage and the Nextcloud client at the same time, hoping to break something but did not succeed.

dragotin commented 1 month ago

Fixed with latest commit.