Skip to content

Instantly share code, notes, and snippets.

View begoon's full-sized avatar
💭
Eating

Alexander Demin begoon

💭
Eating
View GitHub Profile
@eguven
eguven / brew-list.sh
Last active May 20, 2024 01:33
List all packages installed using Homebrew and their sizes
# this original one uses values returned from 'brew info'
brew list --formula | xargs -n1 -P8 -I {} \
sh -c "brew info {} | egrep '[0-9]* files, ' | sed 's/^.*[0-9]* files, \(.*\)).*$/{} \1/'" | \
sort -h -r -k2 - | column -t
# faster alternative using 'du'
du -sch $(brew --cellar)/*/* | sed "s|$(brew --cellar)/\([^/]*\)/.*|\1|" | sort -k1h
@erikh
erikh / hack.sh
Created March 31, 2012 07:02 — forked from DAddYE/hack.sh
OSX For Hackers
#!/usr/bin/env sh
##
# This is script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# install it:
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh
#
@arcusfelis
arcusfelis / tcp_proxy_profile.erl
Created December 12, 2011 16:11
tcp_proxy profile
Eshell V5.8.4 (abort with ^G)
1> c(tcp_proxy, [debug_info, export_all]).
{ok,tcp_proxy}
2> fprof:apply(tcp_proxy, dump_binary, [1,<<"Test 3">>]).
[["000",49],
58,32,
["000",48],
58,32,
["54 65 73 74 20 33 ",
[32,[32," ",32,32,32],32," ",32,32,32],