gem_tools 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,3 +1,6 @@
1
+ == 0.0.9 2009-02-10
2
+ * Fix the a bug in the loaded detection logic
3
+
1
4
  == 0.0.8 2008-11-14
2
5
  * Fix the check for Kernel::gem
3
6
  * Make sure to use the right gem command when checking gems
@@ -2,7 +2,7 @@ module GemTools
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 0
5
- TINY = 8
5
+ TINY = 9
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
data/lib/gem_tools.rb CHANGED
@@ -90,7 +90,7 @@ module GemTools
90
90
  # or the spec version doesn't match the required version
91
91
  # or require_gem returns false
92
92
  # (return false also happens if the gem has already been loaded)
93
- if OPTIONS.has_key?(:force) || !spec || (! loaded && version != gem['version'])
93
+ if OPTIONS.has_key?(:force) || !spec || (! loaded || version != gem['version'])
94
94
  gem_config = gem['config'] ? " -- #{gem['config']}" : ''
95
95
  source = gem['source'] || config['source'] || nil
96
96
  source = "--source #{source}" if source
@@ -108,7 +108,7 @@ module GemTools
108
108
  spec = YAML.load(`#{command} spec #{name} 2> /dev/null`)
109
109
  loaded = false
110
110
  begin
111
- loaded = require_gem name, version
111
+ loaded = defined?(gem) ? gem(name, version) : require_gem(name, version)
112
112
  version = spec.version.version
113
113
  rescue Exception
114
114
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gem_tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Moen
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2008-11-14 00:00:00 -06:00
12
+ date: 2009-02-10 00:00:00 -06:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -20,7 +20,7 @@ dependencies:
20
20
  requirements:
21
21
  - - ">="
22
22
  - !ruby/object:Gem::Version
23
- version: 1.8.2
23
+ version: 1.8.0
24
24
  version:
25
25
  description: A lightweight tool to manage gems using a config file, similar to GemInstaller
26
26
  email:
@@ -69,7 +69,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
69
69
  requirements: []
70
70
 
71
71
  rubyforge_project: underpantsgnome
72
- rubygems_version: 1.2.0
72
+ rubygems_version: 1.3.1
73
73
  signing_key:
74
74
  specification_version: 2
75
75
  summary: A lightweight tool to manage gems using a config file, similar to GemInstaller