[BUGFIX] fix problem with hidden files and dots in pathes

this patch should fix the problems reported in #132 
I'm not sure what is tested here now. After these changes a simple `return true;` should do it?