refactored install process into pieces