Commands by xorg (1)

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

Find directories over 50MB in the home directory

Remove security limitations from PDF documents using ghostscript (for Windows)
#4345 also works under windows

ignore the .svn directory in filename completion
When browsing java source code (for example) it's really annoying having to type the first letter of the package when there is only one package in the subdir. man bash for more info about FIGNORE

cat a bunch of small files with file indication
If you have a bunch of small files that you want to cat to read, you can cat each alone (boring); do a cat *, and you won't see what line is for what file, or do a grep . *. "." will match any string and grep in multifile mode will place a $filename: before each matched line. It works recursively too!!

BASH: Print shell variable into AWK
Alternatively: export MyVAR=84; awk '{ print ENVIRON["MyVAR"] }'

Screen enable/disable loggin in all windows
The command when added in screenrc enables logging all open windows by using the C-l (control-l key combination) and disable by C-o . The lines need to be added in separate lines .

Tail postfix current maillog and grep for "criteria"
Tail curren postfix maillog.

Search for files in rpm repositorys. (Mandriva linux)
Look for an rpm that supplies a specific file that you don't yet have installed. extremely useful when you need something and don't know where it is.. or what its called. note: uses grep like syntax.

Find usb device
I often use it to find recently added ou removed device, or using find in /dev, or anything similar. Just run the command, plug the device, and wait to see him and only him

Check motherboard manufacturer, product name, version and serial number
Very slick way to check your motherboard manufacturer, product name, version and serial number.


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: