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

Open a manpage in the default (graphical) web browser
An easy alias for opening a manpage, nicely HTML formatted, in your set internet browser. If you get a "command exited with status 3" error you need to install groff.

A function to find the newest file in a directory
Works recusivley in the specified dir or '.' if none given. Repeatedly calls 'find' to find a newer file, when no newer files exist you have the newest. In this case 'newest' means most recently modified. To find the most recently created change -newer to -cnewer.

GZip all files in a directory separately

Switch to the previous branch used in git(1)
Very useful if you keep switching between the same two branches all the time.

Real time satellite wheather wallpaper
Changes the wallpaper to the last satellite image. Tha url above shows latin america. Seek the best url for your location Now I have a usefull background image in my desktop I use it inside kalarm updating every 15 minutes. May be done with 'watch' instead It s an option to xplanet ( kde ) and xearth needs xli , curl

mplayer -af scaletempo
Pitch-correct play speed with mplayer. You can also use [] and {} keys to change play speed on-the-fly.

Getting ESP and EIP addresses from running processes
'ps' let you specify the format that you want to see on the output.

Redefine the cd command's behavior
Often, the very next command after the cd command is 'ls', so why not combine them?. Tested on a Red Hat derivative and Mac OS X Leopard Update: changed ${1:-$HOME} to "${@:-$HOME}" to accomodate directories with spaces in the names

Rename files in batch

Search commandlinefu.com and display with VIMs syntax highlighting!
Multi-argument version, but with VIM loveliness :D


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: