{"id":1125,"date":"2007-04-13T01:14:44","date_gmt":"2007-04-12T16:14:44","guid":{"rendered":"http:\/\/www.heavenwolf.org\/blog\/?p=1123"},"modified":"2012-05-09T21:53:58","modified_gmt":"2012-05-09T12:53:58","slug":"20070413011444","status":"publish","type":"post","link":"https:\/\/nao.river24.net\/blog\/entry\/20070413011444\/","title":{"rendered":"mhc2gcal : MHC \u306e\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092 Google Calendar \u306b\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9"},"content":{"rendered":"<p>\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u306e\u5171\u6709\u306b Google Calendar \u3092\u4f7f\u3046\u3053\u3068\u306b\u306a\u308a\uff0c\u5f53\u521d\u306f MHC \u3067\u7ba1\u7406\u3057\u3066\u3044\u308b\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u60c5\u5831\u3092 <a href=\"http:\/\/yuo.nui.org\/Works\/mhc2ical\/?lang=ja\" target=\"_blank\">mhc2ical<\/a> \u3092\u4f7f\u3063\u3066 iCal \u5f62\u5f0f\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u51fa\u529b\u3057\uff0c\u30d6\u30e9\u30a6\u30b6\u304b\u3089\u30a4\u30f3\u30dd\u30fc\u30c8\u4f5c\u696d\u3092\u3057\u3066\u3044\u305f\u306e\u3060\u304c\uff0c\u306a\u3093\u3068\u3082\u9762\u5012\u306a\u306e\u3067\u81ea\u52d5\u5316\u3059\u308b\u3053\u3068\u306b\u3057\u305f\uff0e<\/p>\n<p>\u81ea\u52d5\u5316\u3068\u3044\u3063\u3066\u3082\uff0c\u51fa\u529b\u3057\u305f\u30d5\u30a1\u30a4\u30eb\u3092\u30a4\u30f3\u30dd\u30fc\u30c8\u3059\u308b\u4f5c\u696d\u3092\uff0c\u30d6\u30e9\u30a6\u30b6\u3092\u30a8\u30df\u30e5\u30ec\u30fc\u30c8\u3059\u308b\u30e9\u30a4\u30d6\u30e9\u30ea\u306a\u3069\u3067\u81ea\u52d5\u5316\u3059\u308b\u3060\u3051\u3067\u306f\u306c\u308b\u3044\uff08\u3068\u3044\u3046\u304b\uff0c\u305d\u308c\u306f\u305d\u308c\u3067\u81ea\u5206\u306e\u529b\u91cf\u3067\u306f\u3059\u3050\u306b\u3067\u304d\u308b\u308f\u3051\u3067\u306f\u306a\u3055\u305d\u3046\u3060\u304c\uff09\u3068\u8003\u3048\uff0c\u601d\u3044\u5207\u3063\u3066 Google Calendar Data API \u3092\u4f7f\u3063\u3066 MHC \u306e\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092 Google Calendar \u306b\u76f4\u63a5\u767b\u9332\u3059\u308b\u3053\u3068\u3092\u4f01\u3093\u3060\uff0e<\/p>\n<p>MHC \u306f Ruby \u304b\u3089\u3044\u308d\u3044\u308d\u3068\u3044\u3058\u308c\u308b\u3088\u3046\u306b\u30e9\u30a4\u30d6\u30e9\u30ea\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u308b\uff0e\u305d\u3053\u3067 Google Calendar Data API \u3082 Ruby \u3067\u4f7f\u3046\u3053\u3068\u304c\u3067\u304d\u308c\u3070\uff0c\u4e00\u6c17\u306b\u89e3\u6c7a\u3059\u308b\u306e\u3067\u306f\u306a\u3044\u304b\u3068\u8003\u3048\uff0c\u691c\u7d22\u3057\u3066\u307f\u305f\u3068\u3053\u308d RubyForge \u306b <a href=\"http:\/\/rubyforge.org\/projects\/gcalapi\/\" target=\"_blank\">gcalapi<\/a> \u3092\u767a\u898b\uff0e\u65e9\u901f gem \u3067\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\uff0e\u3053\u308c\u3067\u74b0\u5883\u306f\u6574\u3063\u305f\uff0e<\/p>\n<p>\u3067\uff0c\u5b8c\u6210\u3057\u305f\u30b9\u30af\u30ea\u30d7\u30c8\u304c\uff0c\u305d\u306e\u540d\u3082 mhc2gcal \u3068\u3044\u3046\u5b89\u76f4\u306a\u30cd\u30fc\u30df\u30f3\u30b0\uff0e\u540d\u524d\u304c <a href=\"http:\/\/yuo.nui.org\/Works\/mhc2ical\/?lang=ja\" target=\"_blank\">mhc2ical<\/a> \u304b\u3089\u30a4\u30f3\u30b9\u30d1\u30a4\u30a2\u3055\u308c\u3066\u304a\u308a\uff0c\u307e\u305f\u30d7\u30ed\u30b0\u30e9\u30e0\u3082\u30d9\u30fc\u30b9\u306b\u3055\u305b\u3066\u3044\u305f\u3060\u3044\u305f\uff0e\u307e\u305f <a href=\"http:\/\/rubyforge.org\/projects\/gcalapi\/\" target=\"_blank\">gcalapi<\/a> \u306e example \u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306b\u5165\u3063\u3066\u3044\u305f ol2gcal \u3082\u53c2\u8003\u306b\u3055\u305b\u3066\u3044\u305f\u3060\u3044\u305f\uff0e<\/p>\n<p><span style=\"font-weight: bold; text-decoration: line-through;\">2008\u5e7408\u670819\u65e5\u8ffd\u8a18\uff1a\u6700\u65b0\u7248\u306e\u4f7f\u3044\u65b9\u306f\u3053\u3061\u3089\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\uff0e<\/span><br \/>\n<span style=\"font-weight: bold;\">2009\u5e7410\u670826\u65e5\u8ffd\u8a18\uff1a\u6700\u65b0\u7248\u306e\u4f7f\u3044\u65b9\u306f<a href=\"http:\/\/github.com\/river24\/mhc2gcal\">\u3053\u3061\u3089<\/a>\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\uff0e<\/span><\/p>\n<p><!--more--><\/p>\n<div style=\"text-decoration: line-through;\">\n<p>\u3068\u3044\u3046\u308f\u3051\u3067 mhc2gcal.rb \u306f\u3053\u3061\u3089\uff0e<\/p>\n<p>\u307e\u305a\u306f\u8a2d\u5b9a\uff0e\u4e0a\u8a18\u30b9\u30af\u30ea\u30d7\u30c8\u5185\u306e\u8a72\u5f53\u90e8\u5206\u3092\uff0c\u5404\u81ea\u306e\u74b0\u5883\u306b\u5408\u308f\u305b\u3066\u5909\u66f4\uff0e<\/p>\n<pre class=\"brush: text; gutter: true; first-line: 1; highlight: []; html-script: false\"># google calendar Feed URL\r\nGCAL_FEED = &quot;http:\/\/www.google.com\/calendar\/feeds\/XXXXXXXXXXXXXXXX@group.calendar.google.com\/private\/full&quot;\r\n# email address\r\nGCAL_MAIL = &quot;XXXXXXXXXX@gmail.com&quot;\r\n# password\r\nGCAL_PASS = &quot;XXXXXXX&quot;\r\n# delete events in the period of date from google calendar\r\nGCAL_DEL  = false<\/pre>\n<p>GCAL_FEED \u306f Google Calendar \u306e\u30ab\u30ec\u30f3\u30c0\u30fc\u306e\u500b\u4eba\u7528 URL \u3068\u3044\u3046\u3082\u306e\uff0e\u30ab\u30ec\u30f3\u30c0\u30fc\u306e\u8a73\u7d30\u304b\u3089\u898b\u308b\u3053\u3068\u304c\u3067\u304d\u308b\uff0e\u305f\u3060\u3057 private \u306e\u90e8\u5206\u3068 full \u306e\u90e8\u5206\u306f\uff0c\u9055\u3046\u66f8\u5f0f\u306b\u306a\u3063\u3066\u3044\u308b\u3068\u601d\u3046\u306e\u3067\uff0c<a href=\"http:\/\/code.google.com\/apis\/calendar\/reference.html\" target=\"_blank\">\u3053\u3061\u3089<\/a>\u3092\u53c2\u8003\u306b\u3057\u3066\uff0c\u66f8\u304d\u8fbc\u307f\u306e\u3067\u304d\u308b URL \u306b\u4fee\u6b63\uff0e<br \/>\nGCAL_MAIL \u306f Google Calendar \u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u305f\u3081\u306e\u30e1\u30fc\u30eb\u30a2\u30ab\u30a6\u30f3\u30c8\uff0e\u304a\u305d\u3089\u304f Gmail \u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3060\u3063\u305f\u308a\u3059\u308b\u306e\u3067\u306f\u306a\u304b\u308d\u3046\u304b\uff0e<br \/>\nGCAL_PASS \u306f Google Calendar \u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u305f\u3081\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\uff0e\u3053\u308c\u3082\u540c\u4e0a\uff0e<\/p>\n<p><span style=\"colr: blue; font-weight: bold;\">GCAL_DEL \u306f\u6ce8\u610f\u304c\u5fc5\u8981\uff0e<\/span>\u3053\u306e\u5024\u3092 true \u306b\u3059\u308b\u3068\uff0c\u5f8c\u8ff0\u306e\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u30aa\u30d7\u30b7\u30e7\u30f3\u306a\u3069\u3067\u6307\u5b9a\u3055\u308c\u305f\u671f\u9593\u306e\u30a4\u30d9\u30f3\u30c8\u3092 Google Calendar \u304b\u3089\u524a\u9664\u3057\u307e\u3059\uff0e\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u306f GCAL_DEL \u306e\u5024\u306f false \u306b\u3057\u3066\u3042\u308a\u307e\u3059\uff0e\u3088\u304f\u7406\u89e3\u3057\u305f\u4e0a\u3067\u3054\u5229\u7528\u4e0b\u3055\u3044\uff0e<\/p>\n<p>mhc2gcal \u304c MHC \u304b\u3089 Google Calendar \u3078\u306e\u4e00\u65b9\u7684\u306a\u767b\u9332\u306e\u307f\u3092\u5b9f\u73fe\u3057\u305f\u304f\u3066\u4f5c\u6210\u3057\u305f\u3082\u306e\u3067\u3059\uff0eGoogle Calendar \u306b\u767b\u9332\u3055\u308c\u3066\u3044\u308b\u30a4\u30d9\u30f3\u30c8\u3092\u8003\u616e\u3057\u306a\u3044\u305f\u3081\uff0c\u4f55\u5ea6\u3082\u5b9f\u884c\u3059\u308b\u3068\u30a4\u30d9\u30f3\u30c8\u304c\u91cd\u8907\u3057\u3066\u767b\u9332\u3055\u308c\u3066\u3057\u307e\u3044\u307e\u3059\uff0e\u3053\u308c\u3092\u9632\u3050\u305f\u3081\uff0c\u5f53\u65b9\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u5229\u7528\u65b9\u6cd5\u3092\u60f3\u5b9a\u3057\u3066\u3044\u307e\u3059\uff0e<\/p>\n<ol>\n<li>MHC \u306e\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092\u767b\u9332\u3059\u308b<span style=\"font-weight: bold;\">\u3060\u3051<\/span>\u306e\u30ab\u30ec\u30f3\u30c0\u30fc\u3092 Google Calendar \u306b\u8ffd\u52a0\u3059\u308b\uff0e<\/li>\n<li>\u3053\u306e\u30ab\u30ec\u30f3\u30c0\u30fc\u306f\uff0cGoogle Calendar \u306e\u30a4\u30f3\u30bf\u30d5\u30a7\u30fc\u30b9\u306a\u3069\u304b\u3089\u306f\u95b2\u89a7\u3059\u308b\u3060\u3051\u3067\u30a4\u30d9\u30f3\u30c8\u767b\u9332\u306f\u3057\u306a\u3044\u3088\u3046\u306b\u3057\u307e\u3059\uff0e<\/li>\n<li>\u305d\u306e\u4e0a\u3067\uff0c\u305d\u306e\u30ab\u30ec\u30f3\u30c0\u30fc\u306e\u500b\u4eba\u7528 URL \u3092 GCAL_FEED \u306b\uff0c GCAL_DEL \u306e\u5024\u3092 true \u306b\u8a2d\u5b9a\u3057\u3066\u4f7f\u7528\u3059\u308b\uff0e<\/li>\n<\/ol>\n<p>\u5f53\u65b9\u3067\u306f\u4e0a\u8a18\u306e\u3088\u3046\u306a\u5229\u7528\u65b9\u6cd5\u3067\uff0c\u7279\u306b\u554f\u984c\u306a\u304f\u52d5\u4f5c\u3057\u3066\u3044\u307e\u3059\uff0e<\/p>\n<p>\u6b21\u306b\uff0c\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u30aa\u30d7\u30b7\u30e7\u30f3\u306e\u4e00\u89a7\uff0e<\/p>\n<pre class=\"brush: text; gutter: true; first-line: 1; highlight: []; html-script: false\">  --help               show this message.\r\n  --category=CATEGORY  pick only in CATEGORY.\r\n                       &#039;!&#039; and space separated multiple values are allowed.\r\n  --secret=CATEGORY    change the title of the event to &#039;SECRET&#039;\r\n                       space separated multiple values are allowed.\r\n  --date={string[+n],string-string}\r\n                       set a period of date.\r\n                       string is one of these:\r\n                         today, tomorrow, sun ... sat, yyyymmdd, yyyymm, yyyy\r\n                         yyyymm lists all days in the month and yyyy lists all\r\n                         days in the year.\r\n                         list n+1 days of schedules if +n is given.\r\n                         default value is &#039;today+0&#039;<\/pre>\n<p>\u30d9\u30fc\u30b9\u3068\u306a\u3063\u305f mhc2ical \u3068\u540c\u3058\u90e8\u5206\u304c\u591a\u3044\uff0e\u65b0\u305f\u306b\u8ffd\u52a0\u3057\u305f\u6a5f\u80fd\u3068\u3057\u3066\uff0c\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092\u4ed6\u4eba\u3068\u5171\u6709\u3059\u308b\u3053\u3068\u3092\u76ee\u7684\u3068\u3057\u3066\u4f5c\u6210\u3057\u305f\u306e\u3067\uff0c\u3042\u308b\u30a4\u30d9\u30f3\u30c8\u306e\u8a73\u7d30\u306f\u96a0\u3057\u305f\u3044\u3051\u3069\uff0c\u6642\u9593\u304c\u57cb\u307e\u3063\u3066\u3044\u307e\u3059\u3088\uff0c\u3068\u3044\u3046\u90e8\u5206\u3092\u793a\u3059\u305f\u3081\u306b\uff0c\u7279\u5b9a\u306e\u30ab\u30c6\u30b4\u30ea\u306e\u30a4\u30d9\u30f3\u30c8\u3092 SECRET \u3068\u3044\u3046\u30bf\u30a4\u30c8\u30eb\u306e\u30a4\u30d9\u30f3\u30c8\u3067\u767b\u9332\u3059\u308b\u3088\u3046\u306b\u3057\u305f\uff0e\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u30aa\u30d7\u30b7\u30e7\u30f3\u3067\u306f --secret \u30aa\u30d7\u30b7\u30e7\u30f3\u3067\u6307\u5b9a\u3059\u308b\uff0e<\/p>\n<p>\u6700\u5f8c\u306b\uff0c\u4f7f\u3044\u65b9\u306e\u4f8b\uff0e<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1; highlight: []; html-script: false\">$ ruby mhc2gcal.rb --date=today+90 --category=&quot;!todo !done !holiday&quot; --secret=&quot;private&quot;<\/pre>\n<p>\u4e0a\u8a18\u306e\u3088\u3046\u306a\u30aa\u30d7\u30b7\u30e7\u30f3\u6307\u5b9a\u3067\uff0c\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u52d5\u4f5c\u3059\u308b\uff0e<br \/>\n\u3000\u30fb\u5b9f\u884c\u5f53\u65e5\u304b\u308990\u65e5\u5206\u306e\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092\u767b\u9332\u3059\u308b\uff0e<br \/>\n\u3000\u30fb\u30ab\u30c6\u30b4\u30ea\u304c todo done holiday \u306e\u30a4\u30d9\u30f3\u30c8\u306f\u542b\u3081\u306a\u3044\uff0e<br \/>\n\u3000\u30fb\u30ab\u30c6\u30b4\u30ea\u304c private \u306e\u30a4\u30d9\u30f3\u30c8\u3092 secret \u306b\u6307\u5b9a\u3057\u3066\u30bf\u30a4\u30c8\u30eb\u3092\u96a0\u3059\uff0e<\/p>\n<p>\u3068\u307e\u3041\uff0c\u3053\u3093\u306a\u611f\u3058\uff0e\u672c\u6765\u3067\u3042\u308c\u3070\uff0c\u4e21\u65b9\u5411\u306e\u540c\u671f\u3092\u5b9f\u73fe\u3057\u305f\u3044\u3068\u3053\u308d\u3060\u304c\uff0c\u81ea\u5206\u306e\u5229\u7528\u65b9\u6cd5\u3068\u3057\u3066\u306f\u4eca\u306e\u4ed5\u69d8\u3067\u5341\u5206\u3060\u3063\u305f\u306e\u3067\uff0c\u3068\u308a\u3042\u3048\u305a\u958b\u767a\u7d42\u4e86\uff0e<\/p>\n<p>\u306a\u304a\uff0c\u3053\u306e\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u4f7f\u7528\u3059\u308b\u969b\u306f\uff0c\u4f7f\u7528\u65b9\u6cd5\u306a\u3069\u3092\u3088\u304f\u628a\u63e1\u3057\uff0c\u307e\u305f\u30b9\u30af\u30ea\u30d7\u30c8\u5185\u3067\u4f55\u304c\u884c\u308f\u308c\u308b\u306e\u304b\u3092\u7406\u89e3\u3057\u305f\u4e0a\u3067\uff0c\u3054\u5229\u7528\u3044\u305f\u3060\u3051\u307e\u3059\u3088\u3046\uff0c\u304a\u9858\u3044\u7533\u3057\u4e0a\u3052\u307e\u3059\uff0e\u3053\u306e\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u4f7f\u7528\u3057\u3066\u4f55\u3089\u304b\u306e\u554f\u984c\u304c\u751f\u3058\u305f\u5834\u5408\uff0c\u5f53\u65b9\u306f\u8cac\u4efb\u3092\u8ca0\u3044\u307e\u305b\u3093\u306e\u3067\uff0c\u3054\u4e86\u627f\u4e0b\u3055\u3044\uff0e\u81ea\u5df1\u8cac\u4efb\u3067\u304a\u9858\u3044\u3057\u307e\u3059\uff0e<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u306e\u5171\u6709\u306b Google Calendar \u3092\u4f7f\u3046\u3053\u3068\u306b\u306a\u308a\uff0c\u5f53\u521d\u306f MHC \u3067\u7ba1\u7406\u3057\u3066\u3044\u308b\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u60c5\u5831\u3092 mhc2ical \u3092\u4f7f\u3063\u3066 iCal \u5f62\u5f0f\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u51fa\u529b\u3057\uff0c\u30d6\u30e9\u30a6\u30b6\u304b\u3089\u30a4\u30f3\u30dd\u30fc\u30c8\u4f5c\u696d\u3092\u3057\u3066\u3044\u305f [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[5],"tags":[],"_links":{"self":[{"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/posts\/1125"}],"collection":[{"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/comments?post=1125"}],"version-history":[{"count":4,"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/posts\/1125\/revisions"}],"predecessor-version":[{"id":4655,"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/posts\/1125\/revisions\/4655"}],"wp:attachment":[{"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/media?parent=1125"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/categories?post=1125"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/nao.river24.net\/blog\/wp-json\/wp\/v2\/tags?post=1125"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}