View disable_ssl_node.sh
NODE_TLS_REJECT_UNAUTHORIZED=0 |
View npm_clean_modules.sh
for package in `ls node_modules`; do npm uninstall $package; done; |
View clean-boot.sh
# run it with root user `sudo -s` | |
dpkg --get-selections|grep 'linux-image*'|awk '{print $1}'|egrep -v "linux-image-$(uname -r)|linux-image-generic" |while read n;do apt-get -y remove $n;done |
View inherit.js
function A(x) { | |
this.x = x; | |
}; | |
A.prototype = { | |
log: function () { | |
console.log('A', this.x); | |
} | |
}; |
View .bowerrc.json
{ | |
"directory": "bower_components", | |
"registry": "http://bower.herokuapp.com", | |
"strict-ssl": false | |
} |
View console.js
/** | |
* Example | |
* var colors = ['#f00', '#0f0', 'rgb(0, 0, 255)']; | |
* console.color(colors); | |
*/ | |
console.color = function(arr) { | |
var colorString = arr.map(function(c) { | |
return "%c" + c; | |
}).join("\n"); |