Commands by krishnan (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

Set RGB gamma of secondary monitor
This command first determines whether a second screen is connected. If this is the case, it sets the screen's RGB gamma via xrandr. Useful for cheap or slightly defective monitors with a tint. In this example a yellowing/champagne color deviation is compensated for by decreasing the red and the green portion of the image.

find files beginning with filename* that do not include "string"
Inverse grep, to find files without the string

Adding specific CustomLog for each Virtual Domain of Apache

Number of CPU's in a system
This appears to do the same. Utility is verified to be present on Ubuntu and OpenSuse out-of-the-box.

Open Port Check
also could specify port number: lsof -ni TCP:80

lotto generator

Check if your desired password is already available in haveibeenpwnd database. This command uses the API provided by HIBP

change dinosaur poop into gold
if firefox is running the database is locked, so you need to copy the places.sqlite file temporarily somewhere to be able to query it...

For a $FILE, extracts the path, filename, filename without extension and extension.
Useful for use in other scripts for renaming, testing for extensions, etc.

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


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: