Xdg Basedir for configuration file

Some improvements related to #112.