json and html file listing, root dir os detection