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 md5 = function(sixteen,ffff,length){ | |
var k = [],i=0; | |
var r = [ | |
7, 12, 17, 22, | |
5, 9, 14, 20, | |
4, 11, sixteen, 23, | |
6, 10, 15, 21 |
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 'formula' | |
def mysql_installed? | |
`which mysql_config`.length > 0 | |
end | |
class Php <Formula | |
url 'http://www.php.net/get/php-5.3.3.tar.gz/from/this/mirror' | |
homepage 'http://php.net/' | |
md5 '5adf1a537895c2ec933fddd48e78d8a2' |
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
wget -r -l1 -H -t1 -nd -N -np -A.<EXTENSION> -erobots=off "<URL>" |
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
perl -i -p -e's/find/replace/g' $(ack -l --text from) |
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
ssh -f -L localPort:remote:remotePort -N user@remote |
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 languages = { | |
AB:"Abkhazian", | |
AA:"Afar", | |
AF:"Afrikaans", | |
SQ:"Albanian", | |
AM:"Amharic", | |
AR:"Arabic", | |
HY:"Armenian", | |
AS:"Assamese", | |
AY:"Aymara", |
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
redis-cli DEL `redis-cli KEYS [pattern] | awk '{ print $1 }'` |
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 fs = require('fs'); | |
function requireDir(dir){ | |
var modules = {}; | |
var pathList = fs.readdirSync(dir); | |
var listLength = pathList.length; | |
for( var i = 0; i < listLength; i++ ){ | |
var path = dir+'/'+pathList[i]; | |
var pathStats = fs.statSync(path); | |
// Ensure regular file |
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 fs = require('fs'); | |
var Path = require('path'); | |
function requireDir(dir){ | |
var modules = {}; | |
fs.readdirSync(dir).map(function(name){ | |
return Path.join(dir, name); | |
}).filter(function(path){ | |
return fs.statSync(path).isFile(); |
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
# Print total number of messages in all queues | |
rabbitmqctl list_queues | awk '{s+=$2} END {print s}' | |
# List all queues, sorted by number of queued messages in descending order | |
rabbitmqctl list_queues | sort -nr -k2 | less |
OlderNewer