开发者

Using Org-Mode With the Gnome 3 Calendar

开发者 https://www.devze.com 2023-04-13 08:53 出处:网络
Gnome 3 has a beautiful calendar panel that drops down from the menu bar, and includes a space for your upcoming appointments.By default this appointment manager reads from the calendar in Evolution M

Gnome 3 has a beautiful calendar panel that drops down from the menu bar, and includes a space for your upcoming appointments. By default this appointment manager reads from the calendar in Evolution Mail. I was curious as to whether it's possible to get it working 开发者_开发问答with Org-Mode. I know Evolution can import .ics files and Org-Mode can write them, so that's a start. Does anyone have thoughts as to how you might (a) get the Gnome 3 Calendar working directly with Org-Mode, or (b) set up an efficient sync between Org-Mode and Evolution Mail's calendar, such that it would be reflected in the Gnome 3 Calendar panel?


I assume you already use the org-agenda. What you are looking for is org-write-agenda to get the exported ics file. I'd wrap that function with your own custom sync-cal function. sync-call should go ahead write the agenda /tmp and then you should issue some shell commands (see start-process) to sync with Evolution (how to do that, I do not know). Now, you maybe want to hook your sync-cal function to some file save functions and run it depending on the file name.

Hacky, but that's how I'd do it if I'd use Gnome.


An idea that occurred to me later in the day—a bit circuitous, but possible—is to go through Google Calendar. There are existing Org-Mode scripts for writing to Google Calendar, and a standard procedure in Evolution Mail for reading from Google Calendar. So if you don't mind going through a third party or having calendar updates depend on Internet access, it should be possible to sync through Google. It's not an elegant solution, but it's at least well documented.


For synchronisation between Evolution and a dedicated org file (one-way only, for now), here's a Python script: org-agenda-evolution.

(Disclaimer: (1) I am the author, (2) as of 2022-08, the tool lacks a configuration system, so right now you may have to tweak some top-level constants in the source to make it work for your org-mode setup.)

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号