more refactoring. massing with build scripting.