Fix ../ in paths and add folder support