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

clear MyDNS-ng cache
Occasionally, to force zone updating, cache flush is necessary. This command is better than restart the mydns daemon.

git remove files which have been deleted
It deletes all removed files, updates what was modified, and adds new files.

analyze traffic remotely over ssh w/ wireshark
Please check out my blog article on this for more detail. http://jdubb.net/blog/2009/08/07/monitor-wireshark-capture-real-time-on-remote-host-via-ssh/

Open a file with specified application.
This command require mac os x.

Encode a file to MPEG4 format
Encode video.avi into newvideo.avi using the libav codec to produce an MPEG4 file with a bitrate of 800

List .log files open by a pid
Uses lsof to display the full path of ".log" files opened by a specified PID.

Makes the permissions of file2 the same as file1
same as the chmod example, but should also copy extended access control list attributes. deliberately stolen from: $man setfacl

Create a file of repeated, non-zero
dd can be used with /dev/zero to easily create a file of all zero-bytes. Pipe that through tr and use octal conversions to change the byte values from zero to 0xff (octal 0377). You can replace 0377 with the byte of your choice. You can also use \\0 and \\377 instead of the quoted version.

make pgsql backup and gzip it

Leap year calculation


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: