gem_info 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG CHANGED
@@ -1,3 +1,8 @@
1
+ == 0.1.1 2011-12-28
2
+
3
+ * Silenced deprecation warnings for Rubygems 1.8.x.
4
+ * Fixed %dependencies for Rubygems >= 1.3.6.
5
+
1
6
  == 0.1.0 2011-04-09
2
7
 
3
8
  * Support for Rubygems 1.7.
@@ -39,7 +39,10 @@ module GemInfo
39
39
  end
40
40
 
41
41
  def installed_specs
42
- if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.7.0')
42
+ version = Gem::Version.new(Gem::VERSION)
43
+ if version >= Gem::Version.new('1.8.0')
44
+ Gem::Specification.to_a
45
+ elsif version >= Gem::Version.new('1.7.0')
43
46
  Gem.source_index.gems.values
44
47
  else
45
48
  Gem.source_index.all_gems.values
@@ -116,7 +119,11 @@ module GemInfo
116
119
  expand('%post_install_message'){|spec| spec.post_install_message}
117
120
  expand('%authors'){|spec| spec.authors.join(', ')}
118
121
  expand('%licenses'){|spec| spec.licenses.join(', ')}
119
- expand('%dependencies'){|spec| spec.dependencies.map{|dep| "#{dep.name} #{dep.version_requirements}"}.join(', ')}
122
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.3.6')
123
+ expand('%dependencies'){|spec| spec.dependencies.map{|dep| "#{dep.name} #{dep.requirement}"}.join(', ')}
124
+ else
125
+ expand('%dependencies'){|spec| spec.dependencies.map{|dep| "#{dep.name} #{dep.version_requirements}"}.join(', ')}
126
+ end
120
127
  expand('%path'){|spec| spec.full_gem_path}
121
128
  expand('%%'){|spec| '%'}
122
129
  expand('%N'){|spec| "\n"}
@@ -1,5 +1,5 @@
1
1
  module GemInfo
2
- VERSION = [0, 1, 0]
2
+ VERSION = [0, 1, 1]
3
3
 
4
4
  class << VERSION
5
5
  include Comparable
@@ -1,4 +1,4 @@
1
- require 'spec/spec_helper'
1
+ require 'spec_helper'
2
2
 
3
3
  describe FuzzyMatcher do
4
4
  before do
@@ -1,4 +1,4 @@
1
- require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
1
+ require 'spec_helper'
2
2
 
3
3
  describe Runner do
4
4
  before do
@@ -1,10 +1,8 @@
1
1
  $LOAD_PATH.unshift(File.dirname(__FILE__))
2
2
  $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
3
3
  require 'gem_info'
4
- require 'spec'
5
- require 'spec/autorun'
6
4
 
7
- Spec::Runner.configure do |config|
5
+ RSpec.configure do |config|
8
6
  config.mock_with :mocha
9
7
  end
10
8
 
metadata CHANGED
@@ -1,82 +1,66 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: gem_info
3
- version: !ruby/object:Gem::Version
4
- hash: 27
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.1
5
5
  prerelease:
6
- segments:
7
- - 0
8
- - 1
9
- - 0
10
- version: 0.1.0
11
6
  platform: ruby
12
- authors:
7
+ authors:
13
8
  - George Ogata
14
9
  autorequire:
15
10
  bindir: bin
16
11
  cert_chain: []
17
-
18
- date: 2011-04-09 00:00:00 Z
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
12
+ date: 2011-12-28 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
21
15
  name: ritual
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
16
+ requirement: &70312243135340 !ruby/object:Gem::Requirement
24
17
  none: false
25
- requirements:
26
- - - "="
27
- - !ruby/object:Gem::Version
28
- hash: 19
29
- segments:
30
- - 0
31
- - 3
32
- - 0
18
+ requirements:
19
+ - - ~>
20
+ - !ruby/object:Gem::Version
33
21
  version: 0.3.0
34
22
  type: :development
35
- version_requirements: *id001
36
- - !ruby/object:Gem::Dependency
37
- name: rspec
38
23
  prerelease: false
39
- requirement: &id002 !ruby/object:Gem::Requirement
24
+ version_requirements: *70312243135340
25
+ - !ruby/object:Gem::Dependency
26
+ name: rspec
27
+ requirement: &70312243134840 !ruby/object:Gem::Requirement
40
28
  none: false
41
- requirements:
42
- - - ">="
43
- - !ruby/object:Gem::Version
44
- hash: 3
45
- segments:
46
- - 0
47
- version: "0"
29
+ requirements:
30
+ - - ~>
31
+ - !ruby/object:Gem::Version
32
+ version: 2.7.0
48
33
  type: :development
49
- version_requirements: *id002
50
- - !ruby/object:Gem::Dependency
51
- name: mocha
52
34
  prerelease: false
53
- requirement: &id003 !ruby/object:Gem::Requirement
35
+ version_requirements: *70312243134840
36
+ - !ruby/object:Gem::Dependency
37
+ name: mocha
38
+ requirement: &70312243134460 !ruby/object:Gem::Requirement
54
39
  none: false
55
- requirements:
56
- - - ">="
57
- - !ruby/object:Gem::Version
58
- hash: 3
59
- segments:
60
- - 0
61
- version: "0"
40
+ requirements:
41
+ - - ! '>='
42
+ - !ruby/object:Gem::Version
43
+ version: '0'
62
44
  type: :development
63
- version_requirements: *id003
64
- description: |
65
- A rubygems plugin which adds an 'info' command which prints
45
+ prerelease: false
46
+ version_requirements: *70312243134460
47
+ description: ! 'A rubygems plugin which adds an ''info'' command which prints
48
+
66
49
  information about gems.
67
-
50
+
51
+
68
52
  Unlike the built-in gem commands, it allows fuzzy matching on gem
53
+
69
54
  names and versions by default, and allows precise formatting of the
55
+
70
56
  output, making it easy on the command line and in scripts.
71
57
 
58
+ '
72
59
  email: george.ogata@gmail.com
73
60
  executables: []
74
-
75
61
  extensions: []
76
-
77
62
  extra_rdoc_files: []
78
-
79
- files:
63
+ files:
80
64
  - lib/gem_info/errors.rb
81
65
  - lib/gem_info/fuzzy_matcher.rb
82
66
  - lib/gem_info/runner.rb
@@ -91,38 +75,29 @@ files:
91
75
  - spec/spec_helper.rb
92
76
  homepage: http://github.com/oggy/gem_info
93
77
  licenses: []
94
-
95
78
  post_install_message:
96
79
  rdoc_options: []
97
-
98
- require_paths:
80
+ require_paths:
99
81
  - lib
100
- required_ruby_version: !ruby/object:Gem::Requirement
82
+ required_ruby_version: !ruby/object:Gem::Requirement
101
83
  none: false
102
- requirements:
103
- - - ">="
104
- - !ruby/object:Gem::Version
105
- hash: 3
106
- segments:
107
- - 0
108
- version: "0"
109
- required_rubygems_version: !ruby/object:Gem::Requirement
84
+ requirements:
85
+ - - ! '>='
86
+ - !ruby/object:Gem::Version
87
+ version: '0'
88
+ required_rubygems_version: !ruby/object:Gem::Requirement
110
89
  none: false
111
- requirements:
112
- - - ">="
113
- - !ruby/object:Gem::Version
114
- hash: 3
115
- segments:
116
- - 0
117
- version: "0"
90
+ requirements:
91
+ - - ! '>='
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
118
94
  requirements: []
119
-
120
95
  rubyforge_project:
121
- rubygems_version: 1.7.2
96
+ rubygems_version: 1.8.10
122
97
  signing_key:
123
98
  specification_version: 3
124
99
  summary: Print information about gems.
125
- test_files:
100
+ test_files:
126
101
  - spec/fuzzy_matcher_spec.rb
127
102
  - spec/runner_spec.rb
128
103
  - spec/spec_helper.rb