lib/eco-rake/shell/gpg.rb in eco-rake-0.1.6 vs lib/eco-rake/shell/gpg.rb in eco-rake-0.2.0

- old
+ new

@@ -42,10 +42,11 @@ # 4. `gpg_version_gte?(major: 2, minor: 1)` return `true` # 5. `gpg_version_gte?(major: 2, minor: 3)` return `false` # @return [Boolean] def gpg_version_gte?(major:, minor:) result = shell_gpg_version - return false unless match = result.match(GPG_VERSION_REGEX) + return false unless (match = result.match(GPG_VERSION_REGEX)) + maj = match[:maj].to_i min = match[:min].to_i (maj >= major) && (min >= minor) end end