literate-dotfiles/docs/calendar-contact.html
2022-05-09 10:05:23 +02:00

232 lines
16 KiB
HTML

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<!-- 2022-05-09 lun. 10:04 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<title>Calendar and Contact Configuration</title>
<meta name="author" content="Dehaeze Thomas" />
<meta name="generator" content="Org Mode" />
<link rel="stylesheet" type="text/css" href="./dist/style.css"/>
<script type="text/javascript" src="./dist/script.js"></script>
</head>
<body>
<div id="org-div-home-and-up">
<a accesskey="h" href="./index.html"> UP </a>
|
<a accesskey="H" href="./index.html"> HOME </a>
</div><div id="content" class="content">
<h1 class="title">Calendar and Contact Configuration</h1>
<div id="table-of-contents" role="doc-toc">
<h2>Table of Contents</h2>
<div id="text-table-of-contents" role="doc-toc">
<ul>
<li><a href="#orge53976d"><code>vdirsyncer</code> - Synchronize calendars and contacts</a></li>
<li><a href="#orgfdca9d4"><code>khal</code> - CLI calendar application</a></li>
<li><a href="#org8708dbd"><code>khard</code> - CLI contact application</a></li>
<li><a href="#ics-add"><code>ics-add</code> - Add ICS file to Khal</a></li>
</ul>
</div>
</div>
<div id="outline-container-orge53976d" class="outline-2">
<h2 id="orge53976d"><code>vdirsyncer</code> - Synchronize calendars and contacts</h2>
<div class="outline-text-2" id="text-orge53976d">
<div class="org-src-container">
<pre class="src src-conf">[<span class="org-type">general</span>]
<span class="org-variable-name">status_path</span> = <span class="org-string">"~/.config/vdirsyncer/status/"</span>
[<span class="org-type">pair radicale_calendar</span>]
<span class="org-variable-name">a</span> = <span class="org-string">"radicale_calendar_remote"</span>
<span class="org-variable-name">b</span> = <span class="org-string">"radicale_calendar_local"</span>
<span class="org-variable-name">collections</span> = [<span class="org-string">"76bfc802-3186-e3af-f688-7e165115b4f8"</span>, <span class="org-string">"f78f1649-b54e-7bfe-488d-6a7005a5aa2f"</span>]
<span class="org-variable-name">conflict_resolution</span> = <span class="org-string">"a wins"</span>
[<span class="org-type">storage radicale_calendar_remote</span>]
<span class="org-variable-name">type</span> = <span class="org-string">"caldav"</span>
<span class="org-variable-name">url</span> = <span class="org-string">"https://radicale.tdehaeze.xyz/tdehaeze/"</span>
<span class="org-variable-name">username</span> = <span class="org-string">"tdehaeze"</span>
<span class="org-variable-name">password.fetch</span> = [<span class="org-string">"command"</span>, <span class="org-string">"get-pass"</span>, <span class="org-string">"radicale.tdehaeze.xyz/tdehaeze"</span>]
[<span class="org-type">storage radicale_calendar_local</span>]
<span class="org-variable-name">type</span> = <span class="org-string">"filesystem"</span>
<span class="org-variable-name">path</span> = <span class="org-string">"~/.calendars/radicale/"</span>
<span class="org-variable-name">fileext</span> = <span class="org-string">".ics"</span>
[<span class="org-type">pair esrf_calendar</span>]
<span class="org-variable-name">a</span> = <span class="org-string">"esrf_calendar_remote"</span>
<span class="org-variable-name">b</span> = <span class="org-string">"esrf_calendar_local"</span>
<span class="org-variable-name">collections</span> = [<span class="org-string">"calendar"</span>]
<span class="org-variable-name">conflict_resolution</span> = <span class="org-string">"a wins"</span>
[<span class="org-type">storage esrf_calendar_remote</span>]
<span class="org-variable-name">type</span> = <span class="org-string">"caldav"</span>
<span class="org-variable-name">url</span> = <span class="org-string">"https://calendar.esrf.fr/egroupware/groupdav.php/calendar"</span>
<span class="org-variable-name">username</span> = <span class="org-string">"dehaeze"</span>
<span class="org-variable-name">password.fetch</span> = [<span class="org-string">"command"</span>, <span class="org-string">"get-pass"</span>, <span class="org-string">"esrf.fr/dehaeze"</span>]
[<span class="org-type">storage esrf_calendar_local</span>]
<span class="org-variable-name">type</span> = <span class="org-string">"filesystem"</span>
<span class="org-variable-name">path</span> = <span class="org-string">"~/.calendars/esrf/"</span>
<span class="org-variable-name">fileext</span> = <span class="org-string">".ics"</span>
[<span class="org-type">pair radicale_contacts</span>]
<span class="org-variable-name">a</span> = <span class="org-string">"radicale_contacts_remote"</span>
<span class="org-variable-name">b</span> = <span class="org-string">"radicale_contacts_local"</span>
<span class="org-variable-name">collections</span> = [<span class="org-string">"98ee5e2c-afcf-70e0-c4a2-9fb9de2e97b7"</span>]
<span class="org-variable-name">conflict_resolution</span> = <span class="org-string">"a wins"</span>
[<span class="org-type">storage radicale_contacts_local</span>]
<span class="org-variable-name">type</span> = <span class="org-string">"filesystem"</span>
<span class="org-variable-name">path</span> = <span class="org-string">"~/.contacts/"</span>
<span class="org-variable-name">fileext</span> = <span class="org-string">".vcf"</span>
[<span class="org-type">storage radicale_contacts_remote</span>]
<span class="org-variable-name">type</span> = <span class="org-string">"carddav"</span>
<span class="org-variable-name">url</span> = <span class="org-string">"https://radicale.tdehaeze.xyz/tdehaeze/"</span>
<span class="org-variable-name">username</span> = <span class="org-string">"tdehaeze"</span>
<span class="org-variable-name">password.fetch</span> = [<span class="org-string">"command"</span>, <span class="org-string">"get-pass"</span>, <span class="org-string">"radicale.tdehaeze.xyz/tdehaeze"</span>]
</pre>
</div>
</div>
</div>
<div id="outline-container-orgfdca9d4" class="outline-2">
<h2 id="orgfdca9d4"><code>khal</code> - CLI calendar application</h2>
<div class="outline-text-2" id="text-orgfdca9d4">
<div class="org-src-container">
<pre class="src src-conf">[<span class="org-type">calendars</span>]
[<span class="org-type">[Home]</span>]
<span class="org-variable-name">path</span> = ~/.calendars/radicale/76bfc802-3186-e3af-f688-7e165115b4f8/
<span class="org-variable-name">color</span> = <span class="org-string">"#B8BB26"</span> <span class="org-comment-delimiter"># </span><span class="org-comment">Green</span>
[<span class="org-type">[Thesis]</span>]
<span class="org-variable-name">path</span> = ~/.calendars/radicale/f78f1649-b54e-7bfe-488d-6a7005a5aa2f/
<span class="org-variable-name">color</span> = <span class="org-string">"#FB4934"</span> <span class="org-comment-delimiter"># </span><span class="org-comment">Red</span>
[<span class="org-type">[ESRF]</span>]
<span class="org-variable-name">path</span> = ~/.calendars/esrf/calendar/
<span class="org-variable-name">color</span> = <span class="org-string">"#83A598"</span> <span class="org-comment-delimiter"># </span><span class="org-comment">Blue</span>
[<span class="org-type">[Birthdays]</span>]
<span class="org-variable-name">path</span> = ~/.contacts/98ee5e2c-afcf-70e0-c4a2-9fb9de2e97b7/
<span class="org-variable-name">color</span> = <span class="org-string">"#D3869B"</span> <span class="org-comment-delimiter"># </span><span class="org-comment">aqua</span>
<span class="org-variable-name">type</span> = birthdays
[<span class="org-type">highlight_days</span>]
<span class="org-variable-name">multiple</span> = <span class="org-string">"#FABD2F"</span> <span class="org-comment-delimiter"># </span><span class="org-comment">Yellow</span>
[<span class="org-type">default</span>]
<span class="org-variable-name">highlight_event_days</span> = True
[<span class="org-type">locale</span>]
<span class="org-variable-name">local_timezone</span>= Europe/Berlin
<span class="org-variable-name">default_timezone</span>= Europe/Berlin
<span class="org-variable-name">timeformat</span>= %H:%M
<span class="org-variable-name">dateformat</span>= %d.%m.
<span class="org-variable-name">longdateformat</span>= %d.%m.%Y
<span class="org-variable-name">datetimeformat</span>= %d.%m. %H:%M
<span class="org-variable-name">longdatetimeformat</span>= %d.%m.%Y %H:%M
[<span class="org-type">keybindings</span>]
<span class="org-variable-name">delete</span> = d
<span class="org-variable-name">today</span> = .
<span class="org-variable-name">new</span> = c
</pre>
</div>
</div>
</div>
<div id="outline-container-org8708dbd" class="outline-2">
<h2 id="org8708dbd"><code>khard</code> - CLI contact application</h2>
<div class="outline-text-2" id="text-org8708dbd">
<div class="org-src-container">
<pre class="src src-conf">[<span class="org-type">addressbooks</span>]
[<span class="org-type">[contacts]</span>]
<span class="org-variable-name">path</span> = ~/.contacts/98ee5e2c-afcf-70e0-c4a2-9fb9de2e97b7/
[<span class="org-type">general</span>]
<span class="org-variable-name">debug</span> = no
<span class="org-variable-name">default_action</span> = list
<span class="org-variable-name">editor</span> = vim
<span class="org-variable-name">merge_editor</span> = vimdiff
[<span class="org-type">contact table</span>]
<span class="org-comment-delimiter"># </span><span class="org-comment">display names by first or last name: first_name / last_name</span>
<span class="org-variable-name">display</span> = first_name
<span class="org-comment-delimiter"># </span><span class="org-comment">group by address book: yes / no</span>
<span class="org-variable-name">group_by_addressbook</span> = no
<span class="org-comment-delimiter"># </span><span class="org-comment">reverse table ordering: yes / no</span>
<span class="org-variable-name">reverse</span> = no
<span class="org-comment-delimiter"># </span><span class="org-comment">append nicknames to name column: yes / no</span>
<span class="org-variable-name">show_nicknames</span> = no
<span class="org-comment-delimiter"># </span><span class="org-comment">show uid table column: yes / no</span>
<span class="org-variable-name">show_uids</span> = no
<span class="org-comment-delimiter"># </span><span class="org-comment">sort by first or last name: first_name / last_name</span>
<span class="org-variable-name">sort</span> = last_name
<span class="org-comment-delimiter"># </span><span class="org-comment">localize dates: yes / no</span>
<span class="org-variable-name">localize_dates</span> = yes
<span class="org-comment-delimiter"># </span><span class="org-comment">set a comma separated list of preferred phone number types in descending priority</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">or nothing for non-filtered alphabetical order</span>
<span class="org-variable-name">preferred_phone_number_type</span> = pref, cell, home
<span class="org-comment-delimiter"># </span><span class="org-comment">set a comma separated list of preferred email address types in descending priority</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">or nothing for non-filtered alphabetical order</span>
<span class="org-variable-name">preferred_email_address_type</span> = pref, work, home
[<span class="org-type">vcard</span>]
<span class="org-comment-delimiter"># </span><span class="org-comment">extend contacts with your own private objects</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">these objects are stored with a leading "X-" before the object name in the vcard files</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">every object label may only contain letters, digits and the - character</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">example:</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">private_objects = Jabber, Skype, Twitter</span>
<span class="org-variable-name">private_objects</span> = Jabber, Skype, Twitter
<span class="org-comment-delimiter"># </span><span class="org-comment">preferred vcard version: 3.0 / 4.0</span>
<span class="org-variable-name">preferred_version</span> = <span class="org-highlight-numbers-number">3.0</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">Look into source vcf files to speed up search queries: yes / no</span>
<span class="org-variable-name">search_in_source_files</span> = no
<span class="org-comment-delimiter"># </span><span class="org-comment">skip unparsable vcard files: yes / no</span>
<span class="org-variable-name">skip_unparsable</span> = no
</pre>
</div>
</div>
</div>
<div id="outline-container-ics-add" class="outline-2">
<h2 id="ics-add"><code>ics-add</code> - Add ICS file to Khal</h2>
<div class="outline-text-2" id="text-ics-add">
<p>
This function is useful to easily add an event to <code>khal</code>.
It is for instance used in the <code>mutt</code> configuration.
</p>
<p>
To share an event by email, the currently best way to proceed is to first find the event on <code>khal</code>, press <code>e</code> to export it to a file, and then add this file as an attachment.
</p>
<div class="org-src-container">
<pre class="src src-bash"><span class="org-keyword">if</span> <span class="org-rainbow-delimiters-depth-1">[</span><span class="org-rainbow-delimiters-depth-2">[</span> -f $<span class="org-highlight-numbers-number">1</span> <span class="org-rainbow-delimiters-depth-2">]</span><span class="org-rainbow-delimiters-depth-1">]</span>; <span class="org-keyword">then</span>
<span class="org-variable-name">resp</span>=$<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-sh-quoted-exec">echo</span> -e <span class="org-string">"yes\nno"</span> | rofi -i -only-match -dmenu -p <span class="org-string">"Would you like to add the event:"</span> -mesg <span class="org-string">"`khal printics \"</span><span class="org-string"><span class="org-constant">$</span></span><span class="org-string"><span class="org-variable-name">1</span></span><span class="org-string">\" | tail -n +2`"</span><span class="org-rainbow-delimiters-depth-1">)</span>
<span class="org-keyword">if</span> <span class="org-rainbow-delimiters-depth-1">[</span><span class="org-rainbow-delimiters-depth-2">[</span> <span class="org-string">"</span><span class="org-string"><span class="org-constant">$</span></span><span class="org-string"><span class="org-variable-name">resp</span></span><span class="org-string">"</span> == <span class="org-string">"yes"</span> <span class="org-rainbow-delimiters-depth-2">]</span><span class="org-rainbow-delimiters-depth-1">]</span>; <span class="org-keyword">then</span>
<span class="org-variable-name">calendar</span>=$<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-sh-quoted-exec">echo</span> <span class="org-string">"`khal printcalendars`"</span> | rofi -i -only-match -dmenu -p <span class="org-string">"Save to:"</span><span class="org-rainbow-delimiters-depth-1">)</span>
<span class="org-keyword">if</span> <span class="org-rainbow-delimiters-depth-1">[</span> -z <span class="org-string">"</span><span class="org-string"><span class="org-constant">$</span></span><span class="org-string"><span class="org-variable-name">calendar</span></span><span class="org-string">"</span> <span class="org-rainbow-delimiters-depth-1">]</span>; <span class="org-keyword">then</span>
<span class="org-keyword">exit</span>;
<span class="org-keyword">fi</span>
khal import -a <span class="org-string">"</span><span class="org-string"><span class="org-constant">$</span></span><span class="org-string"><span class="org-variable-name">calendar</span></span><span class="org-string">"</span> --batch <span class="org-string">"</span><span class="org-string"><span class="org-constant">$</span></span><span class="org-string"><span class="org-variable-name">1</span></span><span class="org-string">"</span> &amp;&amp; <span class="org-sh-escaped-newline">\</span>
notify-send --hint=string:x-dunst-stack-tag:fJeNG8gc <span class="org-string">"Calendar"</span> <span class="org-string">"Even added"</span>;
<span class="org-keyword">fi</span>
<span class="org-keyword">fi</span>
</pre>
</div>
</div>
</div>
</div>
<div id="postamble" class="status">
<p class="author">Author: Dehaeze Thomas</p>
<p class="date">Created: 2022-05-09 lun. 10:04</p>
</div>
</body>
</html>