General cleanup

General cleanup and optimization of code and config file support.
Added an option to send an email (using sendemail) when SNP calling is
done.