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

Create package dependency graph
Create Debian package dependency graph using GraphViz

Prepend a text to a file.
Syntax: $ prepend content to add [filename] Uses ed, so no temp files created.

Speed up or slow down video (and audio)
Usage: videospeed video_filename speedchange newfilename videospeed foo.mp4 0.5 foo_slow.mp4 Range of 0.5 (50%) - 2.0 (200%) is valid.

convert wav files to flac
cd to the folder containing the wav files, then convert them all to flac. yeah baby! in ubuntu, to get the flac program just: sudo apt-get install flac flac file input formats are wav, aiff, raw, flac, oga and ogg

Find the package that installed a command

zsh only: access a file when you don't know the path, if it is in PATH
Say you want to execute 'file' on the command 'top' (to determine what type of file it is); but you don't know where 'top' resides: preface the argument with = and zsh will implicitly prepend the path.

Waste time for about 3 minutes
If you're a slow reader and/or you like to ponder, adjust the sleep time to be longer

Show complete URL in netstat output
The -W switch of netstat makes it print complete URL of the connections, which otherwise by default is truncated to fit its default column size. Now to compensate for irregular column sizes, pipe the output to column (-t switch of column prints in tabular form). The only downside to this part is that the very first row, the header, goes pear shape.

list block devices
Shows all block devices in a tree with descruptions of what they are.

Open Vim with two windows
: new command allow to split a Vim screen in two separate windows. Each window can handle its own buffer. Passing the -c new options when Vim start cause to split screen automatically.


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: