All commands (14,187)

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.

Share Your Commands


Check These Out

Human readable directory sizes for current directory, sorted descending

Fast search in man files or bz-files by keyword direct by man or bz files
For example we need find fast where located and described keyword COMMIT_EDITMSG in man files. Here example howto solve it by search with command bzgrep in man files. Generally these files in bz compressed format. You can use another keywords to your search. Common syntax is: bzgrep -lE keyword1 /usr/share/man/man?/optional-keyword-to-refine* or bzgrep -lE keyword1 /usr/share/man/man?/* where optional-keyword-to-refine is optional and may be omitted but used to speedup search Of course you may combine other options for bzgrep (its based on grep)

Find usb device in realtime
Using this command you can track a moment when usb device was attached.

find filenames and directory names that doesn't conform ISO 9660 level 2
You might want to check what file and directory names would be renamed or chopped if you create iso 9660 level 2 image out of them. Use this command to check first.

Remove space and/or tab characters at the end of line
The command removes all space and/or tabulation characters preceding new line

Send email with one or more binary attachments
This command uses mutt to send the mail. You must pipe in a body, otherwise mutt will prompt you for some stuff. If you don't have mutt, it should be dead easy to install.

Fix subtitle timing (for .sub files)
Fix a microdvd (.sub) subtitle timing by making the phrases to appear 600 frames earlier.

Which processes are listening on a specific port (e.g. port 80)
swap out "80" for your port of interest. Can use port number or named ports e.g. "http"

read manpage of a unix command as pdf in preview (Os X)

Show max lengths of all fields in a pipe delimited file with header row


Stay in the loop…

Follow the Tweets.

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.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

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: