adding config dir and fixing outputdir