{"id":21,"date":"2007-08-18T11:44:48","date_gmt":"2007-08-18T16:44:48","guid":{"rendered":"https:\/\/xkahn.zoned.net\/blog\/2007\/08\/18\/reading-private-google-calendars-in-evolution\/"},"modified":"2008-02-13T01:07:35","modified_gmt":"2008-02-13T06:07:35","slug":"reading-private-google-calendars-in-evolution","status":"publish","type":"post","link":"https:\/\/xkahn.zoned.net\/blog\/2007\/08\/18\/reading-private-google-calendars-in-evolution\/","title":{"rendered":"Reading private Google Calendars in Evolution"},"content":{"rendered":"<p>Do not try this.  It&#8217;s not a good idea.  I don&#8217;t endorse it.<\/p>\n<p>That said, I have a Google Calendar that I want to view in Evolution (if just for the nice reminders) but I <strong>don&#8217;t<\/strong> want to make public, and I can&#8217;t use the private URL.  I need Evolution to authenticate to Google, and download the calendar.  If you can use a private URL, there is already a <a href=\"http:\/\/johnnyjacob.wordpress.com\/2006\/04\/30\/google-calendar-in-evolution\/\">good solution<\/a>.<\/p>\n<p>To that end, I made a terrible, horrible, no good patch to allow Evolution to authenticate to Google so I can download my calendar.  The trick is to pre-auth with Google, get the auth token from the result, and store it in GConf.  From there, the patch will make evolution-data-server recognize Google Calendar URLs and send the auth token in a special header.<\/p>\n<p>Before I get to the patch, here are the problems:<\/p>\n<ul>\n<li>Seriously, it&#8217;s an ugly patch<\/li>\n<li>You have to recompile evolution-data-server<\/li>\n<li>Adding an auth token to GConf?!  What are you, nuts?<\/li>\n<li>Evolution may not be able to understand the appointments set by Google&#8217;s calendar<\/li>\n<li>The calendar only updates every once in a while<\/li>\n<li>You can&#8217;t edit the calendar in Evolution<\/li>\n<\/ul>\n<p>Here&#8217;s how to make it work:<\/p>\n<p>First authenticate with Google to get your auth token:<\/p>\n<pre>curl -D - https:\/\/www.google.com\/accounts\/ClientLogin -d accountType=HOSTED_OR_GOOGLE \\\r\n-d Email='<em>username<\/em>%40<em>domain<\/em>' -d Passwd='<em>password<\/em>'  \\\r\n-d service=cl -d source=evolution-testing-0.0.0<\/pre>\n<p>Replace <em>username<\/em> with your email username.  Replace <em>domain<\/em> with your email domain &#8212; this will usually be gmail.com.  Then replace <em>password<\/em> with your google password.<\/p>\n<p>This will return three lines, the last one will look like this:  <tt>Auth=DQAAAGgA...dk3fA5N<\/tt><\/p>\n<p>Then run:<\/p>\n<pre>gconftool-2 --type string -s \/apps\/evolution\/calendar\/gauth <em>authstring<\/em><\/pre>\n<p>You&#8217;ll need to replace <em>authstring<\/em> with the 180+ character string returned by the previous command.<\/p>\n<p>You should only have to do the above once.  Or whenever the auth string<br \/>\nexpires which seems to be very rare, if at all.<\/p>\n<p>Then quit Evolution and kill the data server with this command:<\/p>\n<pre>evolution --force-shutdown<\/pre>\n<p>Start evolution after applying <a href=\"https:\/\/xkahn.zoned.net\/software\/evolution\/google\/evolution-data-server-1.10.2-google-calendar.patch\">this patch<\/a>.<\/p>\n<p>Go to the calendar component and add:<\/p>\n<pre>webcal:\/\/www.google.com\/calendar\/ical\/<em>username<\/em>@<em>domain<\/em>\/private\/full.ics<\/pre>\n<p>as a web calendar.  You&#8217;ll need to replace <em>username<\/em> with your email username and <em>domain<\/em> with your email domain, usually gmail.com.  You&#8217;ll need to check &#8220;Use Secure Connection&#8221; and I recommend that you cache the calendar locally.<\/p>\n<p>Happily it works for me until the <a href=\"http:\/\/edsgcal.wordpress.com\/screenshots-2\/\">real<\/a> <a href=\"http:\/\/www.koders.com\/info.aspx?c=ProjectInfo&amp;pid=FA19932HET9A8PP7EGVTR6EQRA\">solution<\/a> <a href=\"http:\/\/code.google.com\/soc\/2007\/gnome\/appinfo.html?csaid=752B5B84A5A50C80\">is<\/a> <a href=\"http:\/\/mail.gnome.org\/archives\/gnome-soc-list\/2007-August\/msg00035.html\">available<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Do not try this. It&#8217;s not a good idea. I don&#8217;t endorse it. That said, I have a Google Calendar that I want to view in Evolution (if just for the nice reminders) but I don&#8217;t want to make public, and I can&#8217;t use the private URL. I need Evolution to authenticate to Google, and\u2026 <span class=\"read-more\"><a href=\"https:\/\/xkahn.zoned.net\/blog\/2007\/08\/18\/reading-private-google-calendars-in-evolution\/\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,3],"tags":[],"class_list":["post-21","post","type-post","status-publish","format-standard","hentry","category-gnome","category-technology"],"_links":{"self":[{"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/posts\/21","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/comments?post=21"}],"version-history":[{"count":0,"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/posts\/21\/revisions"}],"wp:attachment":[{"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/media?parent=21"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/categories?post=21"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xkahn.zoned.net\/blog\/wp-json\/wp\/v2\/tags?post=21"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}