Skip to content

Instantly share code, notes, and snippets.

@kurotaky
Created June 3, 2013 23:06
Show Gist options
  • Select an option

  • Save kurotaky/5702235 to your computer and use it in GitHub Desktop.

Select an option

Save kurotaky/5702235 to your computer and use it in GitHub Desktop.
簡単にインストールのバージョンチェックを楽にしたい
require 'nokogiri'
require 'open-uri'
require 'tapp'
versions = {
wordpress: '3.5.1',
ec_cube: '2.12.4',
xoops_cube: '2.2.1',
movable_type: '5.2.3',
soy_cms: '1.4.0c',
baser_cms: '2.1.1',
postmail: '6.71'
}
doc = Nokogiri::HTML(open('http://ja.wordpress.org/releases/'))
doc.css('.releases.latest td').tapp.each do |ver|
puts ver
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment