Skip to content

Instantly share code, notes, and snippets.

@kiwofusi
Created July 6, 2014 02:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kiwofusi/0a3ae94aea6f4d597875 to your computer and use it in GitHub Desktop.
Save kiwofusi/0a3ae94aea6f4d597875 to your computer and use it in GitHub Desktop.
2じゃないよURL書き出し
# coding: utf-8
require 'open-uri'
lst = "C:/どこどこ/2.lst"
url = "http://radio.commufa.jp/tokai/ske/"
open(url) do |content|
open(lst, "w") do |f|
f.puts content.read.scan(/tokai_ske\w+\.asx/)[0..4].map{|fname| url + fname }.join("\n")
end
end
2じゃないよの最新5日分のURLを書き出す。
GetASFStreamで読み込む用。
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment