How should I read a file of type "text/calendar"?
I've got a colleague who keeps sending me attached calendar items from an MS Exchange server. Thunderbird and Mutt can't even see the attachment, but if I view the raw message source, it is there, encoded:
Content-Type: multipart/alternative;
boundary="_002_80B708C9C67AE14BA396foo_"
MIME-Version: 1.0
--_002_80B708C9C67AE14BA396foo_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
=20
=20
--_002_80B708C9C67AE14BA396foo_
Content-Type: text/calendar; charset="utf-8"; method=REQUEST
Content-Transfer-Encoding: base64
I can run the text/calendar portion through base64 -d
and read it just fine, but now I have an external text file that looks like ...
BEGIN:VCALENDAR
METHOD:REQUEST
PRODID:Microsoft Exchange Server 2010
VERSION:2.0
BEGIN:VTIMEZONE
TZID:Eastern Standard Time
BEGIN:STANDARD
...
Obviously, this isn't my problem. Exchange is turning out poorly formatted email messages. Nonetheless, the nature of this exchange is such that my life will be muuuch easier if I can just figure out a reliable way to read these invites.
Is there a tool I can use to actually read the calendar file? There seem to be a few different date fields and I can't tell which is which. Is there an automated way to push the file to evolution?
Solution 1:
You can install ThunderBird Lightning extension.
It installs a calendar tool inside ThunderBird, from which you can import **.ics* attachments as appointments.
You can find the "Import" tool under the Lightning menu inside ThunderBird.
By the way, browsing Mozilla forums, I would say Lighting (and Sunbird) have no option to directly import calendar files.
Solution 2:
As for mutt/neomutt you may make use of https://waynemorrison.com/software/vcal — a perl script parsing the vcal attachment. The corresponding entry in .mailcap
should look like
text/calendar; ~/bin/vcal %s; copiousoutput