refactoring of handling of temporary .repodata directory