Skip to content

Instantly share code, notes, and snippets.

@tosik
Created November 12, 2012 06:40
Show Gist options
  • Select an option

  • Save tosik/4057842 to your computer and use it in GitHub Desktop.

Select an option

Save tosik/4057842 to your computer and use it in GitHub Desktop.
# coding: utf-8
require 'open-uri'
module Ikioi
module_function
def run
puts ActiveSupport::JSON.decode(open('http://2ch-ranking.net/ranking.json?board=gameswf')
.read.sub('callback(', '').sub(/\);$/, '')).find {|item| item['title'].include? "あらあらかしこ" }['ikioi']
rescue
puts 0
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment