Following a recent post about shuffle and sample on the command line, I figured there could potentially be a website that aggregates neat tricks with various commands at the command line. People could submit what I like to call “UNIX hacks”, which would be categorized by command, and they’d have a brief description of what the command does. The website could have hover text similar to Genius.com as a means of explaining what each portion of the command does, if necessary.
Here are some examples I’d have on the website:
seq 5 | shuf
seq 100 | shuf -n 5
git log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
for ref in $(git for-each-ref --sort=-committerdate --format="%(refname)" refs/heads/ refs/remotes ); do git log -n1 $ref --pretty=format:"%Cgreen%cr%Creset %C(yellow)%d%Creset %C(bold blue)<%an>%Creset%n" | cat ; done | awk '"'! a["'$0'"]++'