### What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

### Check These Out

du with colored bar graph
A more efficient way, with reversed order to put the focus in the big ones.

rotate a one page pdf to 90 Degrees Clockwise
This can be taken from the pdftk docs http://www.pdflabs.com/docs/pdftk-man-page/ http://www.pdflabs.com/docs/pdftk-cli-examples/ , but the command examples are not simple.

Detect encoding of a text file
This command gives you the charset of a text file, which would be handy if you have no idea of the encoding.

Takes an html file and outputs plain text from it

Get full directory path of a script regardless of where it is run from

escape any command aliases
e.g. if rm is aliased for 'rm -i', you can escape the alias by prepending a backslash: rm [file] # WILL prompt for confirmation per the alias \rm [file] # will NOT prompt for confirmation per the default behavior of the command

List all execs in $PATH, usefull for grepping the resulting list ##Dependancies: bash coreutils Many executables in$PATH have the keyword somewhere other than the beginning in their file names. The command is useful for exploring the executables in $PATH like this.$ find \${PATH//:/ } -executable -type f -printf "%f\n" |grep admin lpadmin time-admin network-admin svnadmin users-admin django-admin shares-admin services-admin

a shell function to print a ruler the width of the terminal window.

Perl Command Line Interpreter
Can also just use the debug mode like this.

Find the package that installed a command

### Stay in the loop…

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: