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

Using commandoutput as a file descriptor
Description is moved to "Sample output" because the html sanitizer for commandlinefu breaks the examples..

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"

See where a shortened url takes you before click

Calculate days on which Friday the 13th occurs (inspired from the work of the user justsomeguy)
Friday is the 5th day of the week, monday is the 1st. Output may be affected by locale.

host - DNS lookup utility
host is a simple utility for performing DNS lookups. It is normally used to convert names to IP addresses and vice versa. When no arguments or options are given, host prints a short summary of its command line arguments and options.

remove password from openssl key file
Strip a password from a openssl key to use with apache httpd server

change dinosaur poop into gold
if firefox is running the database is locked, so you need to copy the places.sqlite file temporarily somewhere to be able to query it...

Convert all JPEG images to MP4
Source: http://superuser.com/a/624574

Turn white color to transparent for a series of png images
mogrify can be used like convert. The difference is that mogrify overwrites files: http://www.imagemagick.org/www/mogrify.html Of course, other source colors can be used as well.

Using the urxvt terminal daemon
- for .xsession use - Advantages of running a urxvt daemon include faster creation time for terminal windows and a lot of saved memory. You can start new terminals as childs of urxvtd by typing urxvtc. Another advantage is, that background jobs are always owned by the urxvtd and will survive as long the daemon is running.


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: