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

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

gain all mp3s in subfolders w/o encoding
This will search all subfolders for mp3's and gain them to more or less sane defaults (without reencoding). http://mp3gain.sourceforge.net/ required!

Remove blank lines

Combine multiple images into a video using ffmpeg
The -start_number can be ignored if sequence starts with 0, otherwise use first number in sequence

add a backup (or any other) suffix to a file
Very helpful when you've got complex filenames and needs to change just some small parts of it. Renaming a file called "i-made-a-small-typo-right-here" to "i-made-a-big-typo-right-here": $ mv -vi i-made-a-{small,big}-typo-right-here You could also copy multiple files, edit, remove, process, etc.

Nginx - print all optional modules before compilation
wget http://nginx.org/download/nginx-1.15.3.tar.gz && tar -xzf 1.15.3.tar.gz && cd nginx-1.15.3

Selecting a random file/folder of a folder
Also looks in subfolders

I finally found out how to use notify-send with at or cron
You can write a script that does this : $remind []

Converting video file (.flv, .avi etc.) to .3gp
ffmpeg -i = input file name -s = set frame size, qcif=176x144 -vcodec = force video codec -r = frame-rate [default = 25] -b = bit-rate [200 kb/s] -acodec = force audio codec -ab = audio bitrate in bits/s [64k] -ac = no. of audio channels [1] -ar = audio sampling frequency [44100 Hz] optional: -sameq = use same video quality as source (implies VBR) -f = force format -y = overwrite output files

Stream your desktop to a remote machine.
This allows you to stream your desktop using vlc to another computer, in this case, 192.168.1.2 on your local network. If you have vlc installed, your all set to try this out. To view your own desktop, just run "vlc screen://" For more info, see http://nerdlogger.com/2008/01/08/stream-your-linuxwindowsmac-desktop-as-video-using-vlc/


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: