Added settings config. fixes #1 and also fixes #5