Where are korganizer events saved?

I have a problem with recently entered events being lost in korganizer. This is because I thought the events were being saved to the file ~/work.ics, but it seems they weren’t as when I reloaded that file the last 15 hours of events were lost.
If I right-click on the “work.ics” calendar in the bottom left pain of korganizer, and then choose “Calendar Properties”, a pop-up appears telling me that the file name is “~/work.ics”. Events do seem to be stored there, but not in a reliable fashion. It seems that events are being cached somewhere else and only written to ~/work.ics occasionally. This is causing me problems backing up my calendar. I can’t find a way to flush the cache (even closing korganizer doesn’t work). Can anyone suggest a solution so that I can immediately backup changes I make to my calendar by copying the file were those changes are stored, or, better still, forcing them to be written to ~/work.ics. Thanks.

@pauls:

First – Welcome to the KDE Discuss Forums!


In KOrganizer, open Settings → Configure KOrganizer… and within the General page select the Calendars tab.

  • All the configured Calendars should be displayed – select the “work” calendar and then press the edit button.
    Your local calendars should be stored in ‘~/.local/share/apps/korganizer/’ directory.

@Franken14679, thanks very much for your reply.

Opening

  • Settings > Configure KOrganizer > General
    and selecting the Calendars tab

does indeed show my calendars. It shows me ~/work.ics, that I mentioned in my initial message. If I click on “Modify” for that calendar I’m shown a pop-up window containing

  • File Name: ~/work.ics

This is what I described in my initial message. It implies that the data of the events I’m adding are being stored in ~/work.ics, however it seems that they are not being stored there regularly, but instead being cached somewhere else first (as I lost 15 hours of edits when I clicked “okay” or “apply” in that pop-up). Where else might the information be stored before it is added to ~/work.ics and how can I force korganizer to update ~/work.ics so that when I backup that file I am backing up all of my most recent calendar entries?

By the way, in “~/.local/share/apps/korganizer/” I only have one file called std.ics, which is empty apart from some header information. I don’t want my calendars to be stored in “~/.local/share/apps/korganizer/” as I don’t want to back up that path. That is why I changed the location to ~/work.ics.

Thanks for your help!