[install]: improved logic