<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
xmlns:slash="http://purl.org/rss/1.0/modules/slash/">
<channel>
    <title>Re: Untitled - pb.stoleyour.com</title>
    <description>Re: Untitled - pb.stoleyour.com</description>
    <atom:link href="http://pb.stoleyour.com/view/rss/09f0981c" rel="self" type="application/rss+xml" />
    <link>http://pb.stoleyour.com/</link>
    <language>en</language>
<item>
    <title>Re: Re: Untitled</title>
    <link>http://pb.stoleyour.com/view/75c74f19</link>
    <pubDate>Fri, 26 Jul 2013 19:07:22 -0400</pubDate>
    <dc:creator>Diminutive Parakeet</dc:creator>
    <guid isPermaLink="false">http://pb.stoleyour.com/view/75c74f19</guid>
    <description><![CDATA[package require http package require json bind pub - !gw2 pub:gw2Stats proc pub:gw2Stats { nick uhost handle channel arg } { set urlMatch &quot;http://gw2stats.net/api/matches.json&quot; set urlRank &quot;http://gw2stats.net/api/ratings.json&quot;&#8230;]]></description>
    <content:encoded><![CDATA[<div class="tcl" style="font-family:monospace;"><ol><li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;"><span style="color: #008000;">package</span> require <span style="color: #008000;">http</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;"><span style="color: #008000;">package</span> require json</div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp;</div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">bind pub - <span style="color: #66cc66;">!</span>gw2 pub:gw2Stats</div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp;</div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;"><span style="color: #ff7700;font-weight:bold;">proc</span> pub:gw2Stats <span style="color: black;">&#123;</span> nick uhost handle channel arg <span style="color: black;">&#125;</span> <span style="color: black;">&#123;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> urlMatch <span style="color: #483d8b;">&quot;http://gw2stats.net/api/matches.json&quot;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> urlRank <span style="color: #483d8b;">&quot;http://gw2stats.net/api/ratings.json&quot;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> jsonMatch <span style="color: black;">&#91;</span><span style="color: #008000;">http</span>::<span style="color: black;">data</span> <span style="color: black;">&#91;</span><span style="color: #008000;">http</span>::<span style="color: black;">geturl</span> <span style="color: #ff3333;">$urlMatch</span><span style="color: black;">&#93;</span><span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> jsonRank <span style="color: black;">&#91;</span><span style="color: #008000;">http</span>::<span style="color: black;">data</span> <span style="color: black;">&#91;</span><span style="color: #008000;">http</span>::<span style="color: black;">geturl</span> <span style="color: #ff3333;">$urlRank</span><span style="color: black;">&#93;</span><span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> apiMatch <span style="color: black;">&#91;</span>json::<span style="color: black;">json2dict</span> <span style="color: #ff3333;">$jsonMatch</span><span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> apiRank <span style="color: black;">&#91;</span>json::<span style="color: black;">json2dict</span> <span style="color: #ff3333;">$jsonRank</span><span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; </div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;"><span style="color: #ff7700;font-weight:bold;">namespace</span> <span style="color: #ff7700;font-weight:bold;">eval</span> gw2Utils <span style="color: black;">&#123;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp;</div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> tsvPath <span style="color: #483d8b;">&quot;tsvgw2/&quot;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; </div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">proc</span> parsePairs <span style="color: black;">&#123;</span> tsvName <span style="color: black;">&#125;</span> <span style="color: black;">&#123;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> f <span style="color: black;">&#91;</span><span style="color: #008000;">open</span> <span style="color: black;">&#91;</span><span style="color: #008000;">file</span> nativename <span style="color: #ff3333;">$gw2Utils</span>::<span style="color: black;">tsvPath</span><span style="color: #ff3333;">$tsvName</span><span style="color: black;">&#93;</span> r<span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">while</span> <span style="color: black;">&#123;</span> <span style="color: black;">&#91;</span><span style="color: #008000;">eof</span> <span style="color: #ff3333;">$f</span><span style="color: black;">&#93;</span> == <span style="color: #ff4500;">0</span> <span style="color: black;">&#125;</span> <span style="color: black;">&#123;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> splitLine <span style="color: black;">&#91;</span><span style="color: #008000;">split</span> <span style="color: black;">&#91;</span><span style="color: #008000;">gets</span> <span style="color: #ff3333;">$f</span><span style="color: black;">&#93;</span> <span style="color: #483d8b;">&quot;<span style="color: #000099; font-weight: bold;">\t</span>&quot;</span><span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">set</span> pairMap<span style="color: black;">&#40;</span><span style="color: black;">&#91;</span><span style="color: #008000;">lindex</span> <span style="color: #ff3333;">$splitLine</span> <span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span><span style="color: black;">&#41;</span> <span style="color: black;">&#91;</span><span style="color: #008000;">lindex</span> <span style="color: #ff3333;">$splitLine</span> <span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: black;">&#125;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">return</span> <span style="color: black;">&#91;</span>array get pairMap<span style="color: black;">&#93;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: black;">&#125;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; </div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">proc</span> insertCommas <span style="color: black;">&#123;</span> num <span style="color: black;">&#123;</span>sep ,<span style="color: black;">&#125;</span> <span style="color: black;">&#125;</span> <span style="color: black;">&#123;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">while</span> <span style="color: black;">&#123;</span> <span style="color: black;">&#91;</span><span style="color: #008000;">regsub</span> <span style="color: black;">&#123;</span>^<span style="color: black;">&#40;</span><span style="color: black;">&#91;</span>-+<span style="color: black;">&#93;</span><span style="color: #66cc66;">?</span>\d+<span style="color: black;">&#41;</span><span style="color: black;">&#40;</span>\d\d\d<span style="color: black;">&#41;</span><span style="color: black;">&#125;</span> <span style="color: #ff3333;">$num</span> <span style="color: #483d8b;">&quot;<span style="color: #000099; font-weight: bold;">\\</span>1$sep<span style="color: #000099; font-weight: bold;">\\</span>2&quot;</span> num<span style="color: black;">&#93;</span> <span style="color: black;">&#125;</span> <span style="color: black;">&#123;</span><span style="color: black;">&#125;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">return</span> <span style="color: #ff3333;">$num</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: black;">&#125;</span></div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; </div></li>
<li style="font-weight: normal; vertical-align:top;"><div style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp; &nbsp; &nbsp; &nbsp; </div></li>
</ol></div>]]></content:encoded>
</item>
</channel>
</rss>
