Semantic version parsing and comparison for ruby