4

I am wondering where the file is that gnome-calendar ("Calendar") stores calendar events in.

I have Ubuntu 20.04 on my desktop and my laptop and I use megaCMD from mega.nz to keep my most important folders in sync between the two devices by syncing those folders to same named folders on my mega root. I don't sync the entire ~ because I have slightly different configurations on the two machines. I want to sync the folder which contains the file that has calendar events for gnome-calendar, or if it is not in ~, copy it somewhere in ~ and sync that file, and then have a start up script to copy it to where the file lives. This way the events will be synced between the two devices.

I have tried using find, but only found the executable, /usr/bin/gnome-calendar and the /usr/share/doc/gnome-calendar/ directory which does not contain anything useful for this purpose. I have searched on duckduckgo and StackExchange for any questions related to this one and found nothing. Does anyone have any idea where the file is?

Note: I have no interest in syncing to a Google calendar as I do not use Google.

vanadium
  • 82,909
  • 6
  • 116
  • 186
Astral Axiom
  • 105
  • 1
  • 9

1 Answers1

4

Gnome Calendar integrates with Evolution. It uses the data structures of Evolution to store your calendar.

A calender is stored in icalendar format in a calendar.ics file, located in a dedicated folder in ~/.local/share/evolution/calendar/. The name of the folder is a random string of 40 letters and numbers.

The calendar is named and registered to the Calendar (or Evolution) application through a text configuration file under ~/.config/evolution/sources/. These configuration files have the extension .source. The file name is the same 40 character string as the folder name where the calendar is stored.

vanadium
  • 82,909
  • 6
  • 116
  • 186
  • Thank you, I will check that out. I did look at some of those .source files because I had considered evolution as an alternative. I did not realize that gnome-calendar integrated with it. I think evolution is auto installed and I removed/purged it a while back when trimming down a lot of packages I had installed over time that were not being used and just re-installed it last night. – Astral Axiom Sep 05 '20 at 12:01
  • Thanks so much :) syncing the .local/share/evolution/ directories works perfectly and the events are on both machines calendars. It required logging out and back in to refresh when I first synced it so I imagine that may be the case for newly added events if both machines are powered on when the event is created, maybe could restart a service instead. – Astral Axiom Sep 05 '20 at 15:53
  • I have a `~/.local/share/evolution/calendar/system/calendar.ics` but there are no events stored in it and no other files in that folder. Is there anywhere else that the database of events are stored? – rob Dec 15 '22 at 09:25