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

Determining the excat memory usages by certain PID
this command gives you the total number of memory usuage and open files by the perticuler PID.

Generate an XKCD #936 style 4 word password
The improvement of this command over Strawp's original alternative is that you can specify the size of the words, in this particular case words between 3 and 5 character's long. It also excludes words that contain apostrophes, if you'd rather keep those words simply substitue [^'] for .

convert unixtime to human-readable with awk
- convert unixtime to human-readable with awk - useful to read logfiles with unix-timestamps, f.e. squid-log: sudo tail -f /var/log/squid3/access.log | awk '{ print strftime("%c ", $1) $0; }

check open ports without netstat or lsof

Hits per hour apache log

An alarm clock using xmms2 and at
Nice little alarm clock to wake you up on time (hopefully). You can also do 'echo "vlc path/to/song" | at 6:00

Suspend, background, and foreground a process
1. Start a process, such as 'top' command 2. # suspend process {ctrl-Z} 3. # background process bg 4. # list all backgrounded jobs jobs 5. # bring it back to foreground fg

Copy files for backup storage
Backup a whole directory copying only updated files.

url shortner using google's shortner api
First get a api key for google url shortner from here https://developers.google.com/url-shortener/ Then replace the API_KEY in the command

Quickly generate an MD5 hash for a text string using OpenSSL


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: