fix empty repository !present? error
fix Repository#path_exists? on empty repository
add factory for RepositoryDirectory
add validation specs
add tests on functionality
rename DirectoriesController to RepositoryDirectoriesController
remove redundant lines