I hereby claim:
- I am thebouv on github.
- I am thebouv (https://keybase.io/thebouv) on keybase.
- I have a public key whose fingerprint is B7B1 E67D A27A 1F47 56EB 4732 2226 E190 8D28 A58E
To claim this, I am signing this object:
// gMarkers is your array of markers | |
var bounds = new google.maps.LatLngBounds(); | |
for(i=0;i<gMarkers.length;i++) { | |
bounds.extend(gMarkers[i].getPosition()); | |
} | |
map.fitBounds(bounds); |
find . -type d -perm 777 -exec chmod 755 {} \; # (for changing the directory permission) | |
find . -type f -perm 777 -exec chmod 644 {} \; # (for changing the file permission) | |
# If they did not have 777 permissions, we easily remove the -perm 777 part. | |
# sourced from: http://serverfault.com/a/363428 |
perl -pi -e 's/you/me/g' file | |
# works with *html or any extension to do all in current directory |
<@elyograg> remember this sentence: collections are made up of shards. shards are made up of replicas. each replica is a core. |
# Very handy one-liner from DDoS Deflate project. Useful just by itself. | |
netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n | |
# As an alias: | |
# alias conncount='netstat -ntu | awk '\''{print $5}'\'' | cut -d: -f1 | sort | uniq -c | sort -nr' |
git --no-pager log --all -n 15 --graph --abbrev-commit --decorate --format=tformat:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an <%ce>%C(reset)' |
export PS1="\[\e[00;36m\]thebouv\[\e[0m\]\[\e[00;37m\]@nurgle:\[\e[0m\]\[\e[00;33m\][\W]\[\e[0m\]\[\e[00;36m\]\$(parse_git_branch):\[\e[0m\]\[\e[00;37m\] \[\e[0m\]" | |
export CLICOLOR=1 | |
export LSCOLORS=ExFxBxDxCxegedabagacad | |
# git branch in prompt | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' | |
} |
LogFormat "%{X-Cluster-Client-IP}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" proxy | |
SetEnvIf X-Cluster-Client-IP "^.*\..*\..*\..*" forwarded | |
CustomLog "logs/access_log" combined env=!forwarded | |
CustomLog "logs/access_log" proxy env=forwarded | |
# http://fishnix.tumblr.com/post/18037951487/x-forwarded-for-in-rackspace-cloud-load-balancers |
ps -ylC httpd --sort:rss | awk '{sum+=$8; ++n} END {print "Tot="sum"("n")";print "Avg="sum"/"n"="sum/n/1024"MB"}' | |
# above is a one liner, not really a script | |
# MaxClients = 80% of max memory on system / average mem from one-liner above |
I hereby claim:
To claim this, I am signing this object: