Skip to content

Commit

Permalink
Provide a better interface to gem version
Browse files Browse the repository at this point in the history
  • Loading branch information
n-rodriguez committed Sep 12, 2024
1 parent ae183e8 commit f30a74e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
13 changes: 12 additions & 1 deletion lib/voight_kampff/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# frozen_string_literal: true

module VoightKampff
VERSION = '2.0.0'
def self.gem_version
Gem::Version.new VERSION::STRING
end

module VERSION
MAJOR = 2
MINOR = 0
TINY = 0
PRE = nil

STRING = [MAJOR, MINOR, TINY, PRE].compact.join('.')
end
end
2 changes: 1 addition & 1 deletion voight_kampff.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ require_relative 'lib/voight_kampff/version'

Gem::Specification.new do |s|
s.name = 'voight_kampff'
s.version = VoightKampff::VERSION
s.version = VoightKampff::VERSION::STRING
s.platform = Gem::Platform::RUBY
s.authors = ['Adam Crownoble']
s.email = ['adam@codenoble.com']
Expand Down

0 comments on commit f30a74e

Please sign in to comment.