Database and Media path

(Gramps 5.2.3 on Windows and Linux)
I ran into an issue in a single user, multiple PC environment.
Meanwhile I run Gramps as a single user on multiple PC. The reason is, that I have a desktop mini tower (LMDE 6) with more screens for office use and a portable notebook (LMDE6) for mobile use. As I did some program testing for Gramps development, I even use a third computer, now with Windows 10.

I work with mainly two databases, a test database, valid, but small and outdated and a “live” database with my actual research.
On each PC I set the database path to a local directory, but I synchronize this path with my personal nextcloud, a cloud based fileserver. As a result, I have access to both databases, wherever I work.
The only restriction, I cannot work at the same time at different PC, but this is neither necessary nor reasonable.

The only problem I have, is configuring the media path on Linux and Windows.

My media files are stored in a directory called media and are organized with a relative path.
Below the media directory are other directories family and person to seperate person and family related documents.
So the relative path of a picture is family/picture1.png.

In Settings → Family tree, there are settings for database and basis media path. In my Linux machine, I set the media path to /home/user/Gramps/media.
So together I get the path /home/user/Gramps/media/family/picture1.png and this is exactly the path, where the picture is stored.
When it comes to a windows machine the base media path is certainly different.
It is C:\Users\User\Gramps\media

My problem is, that this basis media path is stored togehter with the database and so being synchronized over my Nextcloud, meaning that once I adjusted it on a Windows machine, it is wrong on the Linux machine and vice versa.

Do I understand something wrong with the concept, because this is the advantage of a relative path, that I have to set different paths to the starting point, but from there everything would be ok.

Waiting for a comment, whether I am using the concept wrong or whether there is a bug.

The reason this does not work as you would like it to (which would be quite helpful) is indeed that a database stores its own media path. To work around this, you’d need fully separate databases on each machine. You can achieve this by exporting your family tree when done on one machine, and importing it when starting on another, having it synchronized using Nextcloud. If you’re okay with using the command line, Gramps can export and import family trees with a single command each, making it slightly easier/quicker to use for you. This approach avoids interacting with Gramps’ internal storage altogether.

@bartfeenstra
The export-import workaround will certainly work, but is even more handwork, than my workaround.
Because what am I doing manually?
If I switch from a Windows to Linux PC, I go to setting → familiy tree and change the basic media path from C:\Users\User$\Gramps\media to /home/user$/Gramps/media. If I switch Linux to Windows, I have to change in the opposite direction. This is much less work that exporting and importing, it simply bothers…
As I see the issue the path may be database specific, but should be saved in an INI file, like /home/user$/.config/gramps/gramps52/gramps.ini for example…
My problem is, I cannot judge, how much development work this is for minor handwork…

I also wish there was an easier way to work on multiple computers.

1 Like