Commands by jonhansi9 (0)

  • bash: commands not found

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

Substitute spaces in filename with underscore
Substitute spaces in filename with underscore, it work on the first space encountered.

Remove CR LF from a text file
Remove CR LF (CRLF) from a text file. use man:tr to get more info about removing other characters from a file. and even character to character replacements.

Show errors in the kernel ring buffer
Much more useful then parsing syslog

list all crontabs for users
additionally use "find /etc/cron*" for cronscripts

Network Discover in a one liner

Encode text in Base64 using Perl
MIME::Base64 is a part of Perl5 distribution. You can also use decode_base64 for oposite result.

Display rows and columns of random numbers with awk
Displays six rows and five columns of random numbers between 0 and 1. If you need only one column, you can dispense with the "for" loop.

VIM: Replace a string with an incrementing number between marks 'a and 'b (eg, convert string ZZZZ to 1, 2, 3, ...)

HTTP redirect
any HTTP requests to the machine on the specified port will be redirected to http://www.whatevs.com... quick, dirty, works fine for sites w/

grep for minus (-) sign
Use flag "--" to stop switch parsing


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: