Skip to content

Instantly share code, notes, and snippets.

View ngs's full-sized avatar
🎣
Fly Fishing

Atsushi NAGASE ngs

🎣
Fly Fishing
View GitHub Profile
#!/usr/bin/perl -w
use strict;
use warnings;
use CGI;
use SWF::Generator;
use MIME::Base64;
use LWP::UserAgent;
use HTTP::Request::Common;
#!/usr/bin/perl
use strict;
use warnings;
my $key = '25698347741e8e2333f076da';
my $secret = 'f0e582e668f551733cec3394';
my $url = 'http://gdd-2010-quiz-japan.appspot.com/oauth/25698347741e8e2333f076da';
use Data::Dumper;
use OAuth::Lite::Consumer;
package Erockr;
use strict;
use warnings;
use URI;
use URI::Escape;
use Data::Dumper;
use Web::Scraper;
use File::Path qw/mkpath/;
use LWP::Simple;
@ngs
ngs / LittleApps Inc. - Company stamp
Created October 16, 2010 13:22
base64 LittleApps Inc. stamp
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJYAAACaCAYAAABLw7GZAAAACXBIWXMAABcSAAAXEgFnn9JSAAAC2GlDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjajZPLaxRZFIe/6tygkCAMtK9eDJdZSJAklA80Ij7SSWyisW3KRJMgSKf6dneZm+qaW9VxFBHJxqXOMHvxsXDhH+DChSvdKBF8IYh7FUUU3Ki0i+p0V/B5Vl/9zrm/c84tLnTaxSDQKQlzfmScXFZOTk3LFc9IsZ4uMnQV3TAYLBTGAIpBoPkmPj7BAnjY9/38T6OrFLpzYK2E1PuSCl3o+AzUKpNT0yA0kD4ZBRGIc0DaxPr/QHom5utA2ow7QyBuAavcwEQg7gEDbrVYgk4B9FYSNTMJntN1tznPH0C38icOAxsgdVaFI022FkrF4QNAP1ivSmp4BOgF63rZ2zcK9ADPy2bfRMzWRi8aHY85dcTX+bEmr/Nn8oeaniKIss6Sfzh/eGRJP1HcXwAyYDmztQMOsAZSe09Xx4/GbOnT1aF8kx+ZujMB/AWpa4EujMWzpe4whUbh4aPwkTjkyNJHgKFGGQ8PjUcOhY/C4BEy+91KTSHBkhwv8XmJweNv6igkDkfI5lnobTlI+6n9xn5sX7av2a8vZuo97cyCOe65ixfeUUBhWr7NbHOm2N+lxiAaTQXFXGunMDFpYrqyfzHTdnIXL7xT5/MfE1uqRKc+ZlCEzGLwmEehCVEMJrr96PYU+u6ZW+vavR6Lm8cedt89s+yuat9spVpbLf9u1yXPK/Gn2CRGxYDYgRR7xF6xWwyLAbFTjLVOTODjcRKFIaSIxucUctn/W6olfmsApHPKV8ZzpZPLyoKplT2tEk/0F+nfjMmpaRnTdB1uhLB2a1v74GAB1prFthYdhF1voeNBW+vJwOpLcHObWzfzTWvLug+R+icCGKoFp4xXqUZys21vl4NBoJUc9d3+XlnUWhqvUo1CaVSozLwq9R
@ngs
ngs / littleapps-logo.svg
Created October 16, 2010 13:43
LittleApps Inc. logotype SVG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ngs
ngs / basnhrc
Created October 31, 2010 07:42
cli aliases for javascript tools
function closure {
ARG=$@
if [ "$ARG" = '' ]; then
ARG='--help'
fi;
java com.google.javascript.jscomp.CommandLineRunner $ARG 2>&1;
}
@ngs
ngs / 01_jalanspot.t
Created October 31, 2010 08:38
じゃらん 観光ガイドをすクレープする
use strict;
use warnings;
use FindBin;
use lib "$FindBin::RealBin/../lib";
use lib "$FindBin::RealBin/../extlib";
use Data::Dumper;
use Test::More;
use URI;
BEGIN { use_ok 'JalanSpot' }
@ngs
ngs / bashrc
Created November 8, 2010 17:48
ポンパレのハーゲンダッツ
alias ice='perl -MLWP::Simple -le "(my \$i=get q{http://bit.ly/bkKBvA})=~s%.+nt>(\d+).*%\$1%;print \$i"'
var h4=document.getElementsByTagName("h4"),pre=document.getElementsByClassName("prettyprint"),plist=[],n=0; for(var i in pre) { var id = pre[i].id; if(!id) continue; var title = h4[n++].innerHTML; plist.push("<dict><key>DefaultValue</key><"+(/^(:?pl|p5|py|rb)$/.test(id)?"true":"false")+"/><key>Key</key><string>"+id+"</string><key>Title</key><string>"+title+"</string><key>Type</key><string>CheckBox</string></dict>") } prompt("",plist.join(""));
@ngs
ngs / dlyoutube.pl
Created November 10, 2010 12:16
download youtube vids as mp4
#!/usr/bin/env perl -w
# TODO: support cli arguments.
use WWW::YouTube::Download;
my $client = WWW::YouTube::Download->new;
my @ids = qw(
A7h0S1nk9Hk
);