refactor ruby install to more easily support version upgrades