This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var bouncy = require('bouncy'); | |
var server = bouncy(function (req, res, bounce) { | |
setTimeout(function() { | |
bounce('xxx.xxx.xxx.xxx', 8080); | |
}, 8000); | |
}); | |
server.listen(18080); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery('tr.rowBorder td:contains(-0.JPG)').prev().find('input').click() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"^w"="deleteWordBackward:"; | |
"^u"="deleteToBeginningOfParagraph"; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fibonacci1(x) { | |
if (x < 2) { | |
return 1; | |
} | |
return fibonacci1(x - 1) + fibonacci1(x - 2); | |
} | |
var fibonacci2 = (function() { | |
var cache = {}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use strict; | |
use warnings; | |
use feature qw(say); | |
say 'say!'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class MacvimKaoriya < Formula | |
homepage 'http://code.google.com/p/macvim-kaoriya/' | |
head 'https://github.com/splhack/macvim.git' | |
depends_on 'cmigemo-mk' => :build | |
depends_on 'ctags-objc-ja' => :build | |
depends_on 'gettext-mk' => :build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
perl -MTime::Piece -lane 'print localtime(gmtime($F[0]/1000)->epoch)."\t$F[1]"' hoge.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ack -f lib | xargs perl -i -pe 's#\*/\n#*/\n\n/*jshint unused: false */\n# if $. < 7; close ARGV if eof;' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function User(name) { | |
if (!(this instanceof User)) { | |
return new User(name); | |
} | |
this.name = name; | |
} | |
// better way | |
function User(name) { | |
var self = this instanceof User |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
perl -pi -e 's{^(\t+)}{q( ) x (length($1)*4)}e' **/*.js |