This file contains hidden or 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
# alias | |
alias ls='ls -la --col' | |
# JST time | |
sudo cp /usr/share/zoneinfo/Japan /etc/localtime | |
# package for build | |
sudo yum install -y git gcc-c++ openssl-devel make | |
# install nodebrew | |
wget https://raw.github.com/hokaccha/nodebrew/master/nodebrew | |
perl nodebrew setup | |
echo 'export PATH=$HOME/.nodebrew/current/bin:$PATH' >> .bashrc |
This file contains hidden or 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
http { | |
proxy_cache_path /var/cache/nginx levels=1:2 keys_zone=one:8m max_size=3000m inactive=600m; | |
proxy_temp_path /var/tmp; | |
include mime.types; | |
default_type application/octet-stream; | |
sendfile on; | |
keepalive_timeout 65; | |
gzip on; | |
gzip_comp_level 6; |
This file contains hidden or 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
<snippet> | |
<content><![CDATA[base(this, '${1:method}'${2});${0}]]></content> | |
<tabTrigger>base</tabTrigger> | |
<scope>source.js</scope> | |
<description>Base method call</description> | |
</snippet> |
This file contains hidden or 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
node_modules | |
config.js |
This file contains hidden or 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
app.get('/', function(req, res){ | |
var ua = req.header('user-agent'); | |
if(/mobile/i.test(ua)) { | |
res.render('mobile.html'); | |
} else { | |
res.render('desktop.html'); | |
} | |
}); |
This file contains hidden or 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('http'); | |
function wget(host, path, https, callback) { | |
var port = (https) ? 443 : 80, | |
client = http.createClient(port, host, https), | |
request = client.request('get', path, { | |
'host': host | |
}), | |
response_body = ''; |
This file contains hidden or 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 stack_holder = new Error | |
function stackPrepare(e,stacks) { | |
var stack = stacks | |
for(var p in stack[0]) { | |
stack[p] = stack[0][p] | |
} | |
stack.find = function(fn) { | |
console.log(stack) | |
for(var i=0;i<stack.length;i++) { | |
if(stack[i].getFunction() === fn) { |
NewerOlder