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

remove empty lines

Lookup hostname for IP address

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"

Translates a phrase from English to Portuguese
Translates a string from English to Portuguese by using google translator web service.

Create A Continuous Yahoo! News Ticker For The Terminal
This creates a permanent stock ticker in the terminal. it has scrolling action and refreshes when each cycle is done to get the latest news.

Yet Another Rename (bash function)
Implementation of `rename` for systems on which I don't have access to it.

Creates a 'path' command that always prints the full path to any file
The command creates an alias called 'path', so it's useful to add it to your .profile or .bash_profile. The path command then prints the full path of any file, directory, or list of files given. Soft links will be resolved to their true location. This is especially useful if you use scp often to copy files across systems. Now rather then using pwd to get a directory, and then doing a separate cut and paste to get a file's name, you can just type 'path file' and get the full path in one operation.

encrypt and post or get and decrypt from sprunge using gpg symmetric encryption option
create simple encrypted notes to yourself using a passphrase on sprunge.us

Prepend a text to a file.
The original command is great, but I often want to prepend to every line.

Graphical tree of sub-directories with files
The command finds every item within the directory and edits the output so that subdirectories are and files are output much like the tree command


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: