#!/usr/bin/env ruby require 'uri' nip = BBS.new('http://ex14.vip2ch.com/news4ssnip') th = nip.thread(1453640864) # Part 38 th.each do |post| URI.extract(post.body.each) do |uri| if %r{https?://ex14\.vip2ch\.com/test/read\.cgi/news4ssnip/(\d+)/} === uri nip.submit('乙', key: $1, mail: 'sage') end end end