Tips Developer

  • Increase font size
  • Default font size
  • Decrease font size
Home Linux
Linux Tips

Change default editor to mcedit

E-mail Print PDF

Run command:

# export EDITOR=mcedit

Last Updated on Friday, 09 December 2011 14:30
 

How to add BR tag on end of each line in text file

E-mail Print PDF

Just run this:

# while read line ; do echo $line <br> >> newfile ; done < oldfile

Last Updated on Friday, 09 December 2011 14:42
 

Autologin to mysql from bash

E-mail Print PDF

You just should to create config file in your home directory.

File name: .my.cnf

Source of the file (example):

[client]
host=db.tipsdeveloper.com
user=tipsdeveloper
password=VerySecretPassword123$%^

Last Updated on Tuesday, 19 July 2011 11:20
 

Simple .htaccess 301 redirection

E-mail Print PDF

At the beginning be sure that parameter AllowOverride in Apache configuration is set propertly:

AllowOverride FileInfo

Then create .htaccess file in any directory and put line:

Redirect 301 /old_location http://full_url/new_location

Last Updated on Wednesday, 20 April 2011 08:38
 

Basic Exim configuration

E-mail Print PDF

Configure MTA (Mail Transfer Agent) to sending mails. No more, no less, just sendig mails using Exim as local SMTP.

Run linux command:

# dpkg-reconfigure exim4-config

and follow by screens:

.

Info: Fill all filelds as on screen. Leave filed empty if field on screen is empty.

Last Updated on Tuesday, 19 April 2011 09:20
 

Google +1 Button


Tips Menu