RubyTorrent是一个纯Ruby的BT客户端工具包,使用示例:
##world'ssmallestbittorrentclientrequire'rubytorrent'bt=RubyTorrent::BitTorrent.new(ARGV.shift)thread=Thread.newdowhiletrueputsbt.percent_completedsleep15endendbt.on_event(self,:complete){thread.kill}thread.join点击空白处退出提示
评论