Sha256: 62ae5a38f46277619f16a020dca493f1f1f93ddc0381b1dc38d2ddf1f052d5d7
Contents?: true
Size: 487 Bytes
Versions: 1
Compression:
Stored size: 487 Bytes
Contents
require 'sem_version' module Incr module Service class Version def self.increment_segment(version, segment) incremented_version = version.clone case segment when 'major' incremented_version.major = version.major + 1 when 'minor' incremented_version.minor = version.minor + 1 when 'patch' incremented_version.patch = version.patch + 1 end incremented_version end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
incr-0.1.2 | lib/incr/service/version.rb |