diff options
author | elijah <elijah@riseup.net> | 2015-05-04 16:34:44 -0700 |
---|---|---|
committer | elijah <elijah@riseup.net> | 2015-05-04 16:34:44 -0700 |
commit | 142468636189f36ee542245856ef4ca84bda0509 (patch) | |
tree | 7efb85c9e575f2ae048592136a92ec9235a9b042 | |
parent | 6b35bbbe1a9909c737c1cd53edcfc47af0ad063c (diff) |
gemspec clean up: remove gems 'tee' and 'versionomy', and tighten dependency version requirements.
-rw-r--r-- | leap_cli.gemspec | 18 | ||||
-rw-r--r-- | lib/leap/platform.rb | 16 |
2 files changed, 15 insertions, 19 deletions
diff --git a/leap_cli.gemspec b/leap_cli.gemspec index b9bad48..6f8f8de 100644 --- a/leap_cli.gemspec +++ b/leap_cli.gemspec @@ -43,17 +43,16 @@ spec = Gem::Specification.new do |s| ## # test - s.add_development_dependency('minitest') + s.add_development_dependency('minitest', '~> 5.0') #s.add_development_dependency('rdoc') #s.add_development_dependency('aruba') # console gems - s.add_runtime_dependency('gli','~> 2.12.0') - s.add_runtime_dependency('command_line_reporter') - s.add_runtime_dependency('highline') - s.add_runtime_dependency('paint') - s.add_runtime_dependency('tee') + s.add_runtime_dependency('gli','~> 2.12') + s.add_runtime_dependency('command_line_reporter', '~> 3.3') + s.add_runtime_dependency('highline', '~> 1.6') + s.add_runtime_dependency('paint', '~> 0.9') # network gems s.add_runtime_dependency('net-ssh', '~> 2.7.0') @@ -68,10 +67,9 @@ spec = Gem::Specification.new do |s| # also, there is a ruby-gpgme package anyway. # misc gems - s.add_runtime_dependency('ya2yaml') # pure ruby yaml, so we can better control output. see https://github.com/afunai/ya2yaml - s.add_runtime_dependency('json_pure') # pure ruby json, so we can better control output. - s.add_runtime_dependency('versionomy') # compare version strings - s.add_runtime_dependency('base32') # base32 encoding + s.add_runtime_dependency('ya2yaml', '~> 0.31') # pure ruby yaml, so we can better control output. see https://github.com/afunai/ya2yaml + s.add_runtime_dependency('json_pure', '~> 1.8') # pure ruby json, so we can better control output. + s.add_runtime_dependency('base32', '~> 0.3') # base32 encoding ## ## DEPENDENCIES for VENDORED GEMS diff --git a/lib/leap/platform.rb b/lib/leap/platform.rb index 3e1d138..0fdb312 100644 --- a/lib/leap/platform.rb +++ b/lib/leap/platform.rb @@ -1,5 +1,3 @@ -require 'versionomy' - module Leap class Platform @@ -34,24 +32,24 @@ module Leap self.instance_eval(&block) - @version ||= Versionomy.parse("0.0") + @version ||= Gem::Version.new("0.0") end def version=(version) - @version = Versionomy.parse(version) + @version = Gem::Version.new(version) end def compatible_cli=(range) @compatible_cli = range - @minimum_cli_version = Versionomy.parse(range.first) - @maximum_cli_version = Versionomy.parse(range.last) + @minimum_cli_version = Gem::Version.new(range.first) + @maximum_cli_version = Gem::Version.new(range.last) end # # return true if the cli_version is compatible with this platform. # def compatible_with_cli?(cli_version) - cli_version = Versionomy.parse(cli_version) + cli_version = Gem::Version.new(cli_version) cli_version >= @minimum_cli_version && cli_version <= @maximum_cli_version end @@ -62,8 +60,8 @@ module Leap if range.is_a? String range = range.split('..') end - minimum_platform_version = Versionomy.parse(range.first) - maximum_platform_version = Versionomy.parse(range.last) + minimum_platform_version = Gem::Version.new(range.first) + maximum_platform_version = Gem::Version.new(range.last) @version >= minimum_platform_version && @version <= maximum_platform_version end |