refactoring block to create plugins directories