{"blog_url":"https://obelisk.hatenablog.com/","title":"RubyPico \u3067\u30d5\u30a1\u30a4\u30eb\u3092 Gist \u306b\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3059\u308b","version":"1.0","provider_url":"https://hatena.blog","categories":["RubyPico"],"author_url":"https://blog.hatena.ne.jp/obelisk2/","published":"2017-05-02 17:59:44","provider_name":"Hatena Blog","blog_title":"Camera Obscura","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fobelisk.hatenablog.com%2Fentry%2F2017%2F05%2F02%2F175944\" title=\"RubyPico \u3067\u30d5\u30a1\u30a4\u30eb\u3092 Gist \u306b\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3059\u308b - Camera Obscura\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","image_url":null,"width":"100%","author_name":"obelisk2","description":"GitHub \u3067 API\u7528\u306e token \u3092\u53d6\u5f97\u3057\u3066\u4e0b\u3055\u3044(\u53c2\u7167)\u3002\u305d\u308c\u3092\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u306e\u300c***\u300d\u306e\u3068\u3053\u308d\u306b\u5165\u308c\u307e\u3059\u3002\u3042\u3068\u306f\u5b9f\u884c\u3059\u308b\u3060\u3051\u3002\u30b3\u30fc\u30c9\u306e\u4fdd\u5b58\u7528\u306b\u3082\u4f7f\u3048\u307e\u3059\u306d\u3002upload_to_gist.rb def main fname = Popup.input(\"\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u5165\u529b\u3057\u3066\u4e0b\u3055\u3044\") return unless fname unless File.exist?(fname) and File.file?(fname) puts \"\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3057\u306a\u3044\u304b\u3001\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3067\u3059\" return end file_content = File.open(fname) {|io| io.read\u2026","type":"rich","url":"https://obelisk.hatenablog.com/entry/2017/05/02/175944","height":"190"}