Commands by ashleyridley007 (0)

  • bash: commands not found

What's this? 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

SSH Auto-login with password
You need to install "sshpass" for this to work. apt-get install sshpass

colorize your svn diff
Will colorize your svn diff.

Oneliner to get domain names list of all existing domain names (from wikipedia)
Quietly get a webpage from wikipedia: curl -s By default, don't output anything: sed -n Search for interesting lines: /<tr valign="top">/ With the matching lines: {} Search and replace any html tags: s/<[^>]*>//g Finally print the result: p

Using bash inline
There are two ways to use "here documents" with bash to fill stdin: The following example shows use with the "bc" command. a) Using a delimiter at the end of data: $ less-than less-than eeooff bc > k=1024 > m=k*k > g=k*m > g > eeooff 1073741824 b) using the "inline" verion with three less-than symbols: $ less-than less-than less-than "k=1024; m=k*k; g=k*m; g" bc 1073741824 One nice advantage of using the triple less-than version is that the command can easily be recalled from command line history and re-executed. PS: in this "description", I had to use the name "less-than" to represent the less-than symbol because the commandlinefu input text box seems to eat up the real less-than symbols. Odd.

Drop all tables from a database, without deleting it

HOME USE ONLY: Get rid of annoying Polkit password prompts
Although the need to type a password to make certain changes to the system may make perfect sense in a business or educational environment, it makes absolutely zero sense to the home user. So, if you’re at home and would rather get work done than be annoyed by what is essentially Linux’s UAC, then this command is for you.

To Stop or Start (Restart) a Windows service from a Linux machine

Mac osx friendly version of this terminal typing command at 200ms per key

Loop over the days of a month, in $YYYY$MM$DD format
Edit YYYY and MM at the beginning of the command with the year and month you want. Note that `DD=$(printf "%02d" $d)` will pad single digit integers with a leading zero. Substitute `echo $YYYY$MM$DD` at the end of the line with the command you want to launch, for instance --yyyymmdd $YYYY$MM$DD Also available on GitHub as bash util:

Purge configuration file of all desinstalled package

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.


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: