Move files to directories, add namespaces