Rebuild directory structure