gem_info 0.0.1 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/CHANGELOG +7 -0
- data/Rakefile +1 -49
- data/lib/gem_info/runner.rb +5 -1
- data/lib/gem_info/version.rb +11 -0
- metadata +46 -30
- data/.document +0 -5
- data/.gitignore +0 -5
- data/DESCRIPTION +0 -6
- data/README.rdoc +0 -55
- data/VERSION +0 -1
- data/gem_info.gemspec +0 -70
data/CHANGELOG
ADDED
data/Rakefile
CHANGED
@@ -1,49 +1 @@
|
|
1
|
-
require '
|
2
|
-
require 'rake'
|
3
|
-
|
4
|
-
begin
|
5
|
-
require 'jeweler'
|
6
|
-
Jeweler::Tasks.new do |gem|
|
7
|
-
gem.name = "gem_info"
|
8
|
-
gem.summary = "Print information about gems."
|
9
|
-
gem.description = File.read('DESCRIPTION')
|
10
|
-
gem.email = "george.ogata@gmail.com"
|
11
|
-
gem.homepage = "http://github.com/oggy/gem_info"
|
12
|
-
gem.authors = ["George Ogata"]
|
13
|
-
gem.required_rubygems_version = '>= 1.3.2' # 1.3.2 introduced plugins
|
14
|
-
gem.add_development_dependency "rspec"
|
15
|
-
gem.add_development_dependency "mocha"
|
16
|
-
end
|
17
|
-
rescue LoadError
|
18
|
-
puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
|
19
|
-
end
|
20
|
-
|
21
|
-
require 'spec/rake/spectask'
|
22
|
-
Spec::Rake::SpecTask.new(:spec) do |spec|
|
23
|
-
spec.libs << 'lib' << 'spec'
|
24
|
-
spec.spec_files = FileList['spec/**/*_spec.rb']
|
25
|
-
end
|
26
|
-
|
27
|
-
Spec::Rake::SpecTask.new(:rcov) do |spec|
|
28
|
-
spec.libs << 'lib' << 'spec'
|
29
|
-
spec.pattern = 'spec/**/*_spec.rb'
|
30
|
-
spec.rcov = true
|
31
|
-
end
|
32
|
-
|
33
|
-
task :spec => :check_dependencies
|
34
|
-
|
35
|
-
task :default => :spec
|
36
|
-
|
37
|
-
require 'rake/rdoctask'
|
38
|
-
Rake::RDocTask.new do |rdoc|
|
39
|
-
if File.exist?('VERSION')
|
40
|
-
version = File.read('VERSION')
|
41
|
-
else
|
42
|
-
version = ""
|
43
|
-
end
|
44
|
-
|
45
|
-
rdoc.rdoc_dir = 'rdoc'
|
46
|
-
rdoc.title = "gem_info #{version}"
|
47
|
-
rdoc.rdoc_files.include('README*')
|
48
|
-
rdoc.rdoc_files.include('lib/**/*.rb')
|
49
|
-
end
|
1
|
+
require 'ritual'
|
data/lib/gem_info/runner.rb
CHANGED
@@ -39,7 +39,11 @@ module GemInfo
|
|
39
39
|
end
|
40
40
|
|
41
41
|
def installed_specs
|
42
|
-
Gem.
|
42
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.7.0')
|
43
|
+
Gem.source_index.gems.values
|
44
|
+
else
|
45
|
+
Gem.source_index.all_gems.values
|
46
|
+
end
|
43
47
|
end
|
44
48
|
|
45
49
|
def validate_exactly_one(specs)
|
metadata
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gem_info
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
4
|
+
hash: 27
|
5
|
+
prerelease:
|
5
6
|
segments:
|
6
7
|
- 0
|
7
|
-
- 0
|
8
8
|
- 1
|
9
|
-
|
9
|
+
- 0
|
10
|
+
version: 0.1.0
|
10
11
|
platform: ruby
|
11
12
|
authors:
|
12
13
|
- George Ogata
|
@@ -14,35 +15,54 @@ autorequire:
|
|
14
15
|
bindir: bin
|
15
16
|
cert_chain: []
|
16
17
|
|
17
|
-
date:
|
18
|
-
default_executable:
|
18
|
+
date: 2011-04-09 00:00:00 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
|
-
name:
|
21
|
+
name: ritual
|
22
22
|
prerelease: false
|
23
23
|
requirement: &id001 !ruby/object:Gem::Requirement
|
24
|
+
none: false
|
24
25
|
requirements:
|
25
|
-
- - "
|
26
|
+
- - "="
|
26
27
|
- !ruby/object:Gem::Version
|
28
|
+
hash: 19
|
27
29
|
segments:
|
28
30
|
- 0
|
29
|
-
|
31
|
+
- 3
|
32
|
+
- 0
|
33
|
+
version: 0.3.0
|
30
34
|
type: :development
|
31
35
|
version_requirements: *id001
|
32
36
|
- !ruby/object:Gem::Dependency
|
33
|
-
name:
|
37
|
+
name: rspec
|
34
38
|
prerelease: false
|
35
39
|
requirement: &id002 !ruby/object:Gem::Requirement
|
40
|
+
none: false
|
36
41
|
requirements:
|
37
42
|
- - ">="
|
38
43
|
- !ruby/object:Gem::Version
|
44
|
+
hash: 3
|
39
45
|
segments:
|
40
46
|
- 0
|
41
47
|
version: "0"
|
42
48
|
type: :development
|
43
49
|
version_requirements: *id002
|
50
|
+
- !ruby/object:Gem::Dependency
|
51
|
+
name: mocha
|
52
|
+
prerelease: false
|
53
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
54
|
+
none: false
|
55
|
+
requirements:
|
56
|
+
- - ">="
|
57
|
+
- !ruby/object:Gem::Version
|
58
|
+
hash: 3
|
59
|
+
segments:
|
60
|
+
- 0
|
61
|
+
version: "0"
|
62
|
+
type: :development
|
63
|
+
version_requirements: *id003
|
44
64
|
description: |
|
45
|
-
A rubygems plugin which adds an
|
65
|
+
A rubygems plugin which adds an 'info' command which prints
|
46
66
|
information about gems.
|
47
67
|
|
48
68
|
Unlike the built-in gem commands, it allows fuzzy matching on gem
|
@@ -54,55 +74,51 @@ executables: []
|
|
54
74
|
|
55
75
|
extensions: []
|
56
76
|
|
57
|
-
extra_rdoc_files:
|
58
|
-
|
59
|
-
- README.rdoc
|
77
|
+
extra_rdoc_files: []
|
78
|
+
|
60
79
|
files:
|
61
|
-
- .document
|
62
|
-
- .gitignore
|
63
|
-
- DESCRIPTION
|
64
|
-
- LICENSE
|
65
|
-
- README.rdoc
|
66
|
-
- Rakefile
|
67
|
-
- VERSION
|
68
|
-
- gem_info.gemspec
|
69
|
-
- lib/gem_info.rb
|
70
80
|
- lib/gem_info/errors.rb
|
71
81
|
- lib/gem_info/fuzzy_matcher.rb
|
72
82
|
- lib/gem_info/runner.rb
|
83
|
+
- lib/gem_info/version.rb
|
84
|
+
- lib/gem_info.rb
|
73
85
|
- lib/rubygems_plugin.rb
|
86
|
+
- CHANGELOG
|
87
|
+
- LICENSE
|
88
|
+
- Rakefile
|
74
89
|
- spec/fuzzy_matcher_spec.rb
|
75
90
|
- spec/runner_spec.rb
|
76
91
|
- spec/spec_helper.rb
|
77
|
-
has_rdoc: true
|
78
92
|
homepage: http://github.com/oggy/gem_info
|
79
93
|
licenses: []
|
80
94
|
|
81
95
|
post_install_message:
|
82
|
-
rdoc_options:
|
83
|
-
|
96
|
+
rdoc_options: []
|
97
|
+
|
84
98
|
require_paths:
|
85
99
|
- lib
|
86
100
|
required_ruby_version: !ruby/object:Gem::Requirement
|
101
|
+
none: false
|
87
102
|
requirements:
|
88
103
|
- - ">="
|
89
104
|
- !ruby/object:Gem::Version
|
105
|
+
hash: 3
|
90
106
|
segments:
|
91
107
|
- 0
|
92
108
|
version: "0"
|
93
109
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
110
|
+
none: false
|
94
111
|
requirements:
|
95
112
|
- - ">="
|
96
113
|
- !ruby/object:Gem::Version
|
114
|
+
hash: 3
|
97
115
|
segments:
|
98
|
-
-
|
99
|
-
|
100
|
-
- 2
|
101
|
-
version: 1.3.2
|
116
|
+
- 0
|
117
|
+
version: "0"
|
102
118
|
requirements: []
|
103
119
|
|
104
120
|
rubyforge_project:
|
105
|
-
rubygems_version: 1.
|
121
|
+
rubygems_version: 1.7.2
|
106
122
|
signing_key:
|
107
123
|
specification_version: 3
|
108
124
|
summary: Print information about gems.
|
data/.document
DELETED
data/DESCRIPTION
DELETED
@@ -1,6 +0,0 @@
|
|
1
|
-
A rubygems plugin which adds an `info' command which prints
|
2
|
-
information about gems.
|
3
|
-
|
4
|
-
Unlike the built-in gem commands, it allows fuzzy matching on gem
|
5
|
-
names and versions by default, and allows precise formatting of the
|
6
|
-
output, making it easy on the command line and in scripts.
|
data/README.rdoc
DELETED
@@ -1,55 +0,0 @@
|
|
1
|
-
= Gem Info
|
2
|
-
|
3
|
-
A rubygems plugin which adds an `info' command that prints information
|
4
|
-
about installed gems.
|
5
|
-
|
6
|
-
Unlike the built-in gem commands, it allows fuzzy matching on gem
|
7
|
-
names and versions by default, and allows precise formatting of the
|
8
|
-
output, making it easy on the command line and in scripts.
|
9
|
-
|
10
|
-
== Examples
|
11
|
-
|
12
|
-
View dependencies at a glance:
|
13
|
-
|
14
|
-
$ gem info -f '%name-%version: %dependencies' act
|
15
|
-
activesupport-2.3.3:
|
16
|
-
activesupport-2.3.4:
|
17
|
-
activeresource-2.3.4: activesupport = 2.3.4
|
18
|
-
activerecord-2.3.4: activesupport = 2.3.4
|
19
|
-
actionpack-2.3.4: activesupport = 2.3.4, rack ~> 1.0.0
|
20
|
-
actionmailer-2.3.4: actionpack = 2.3.4
|
21
|
-
|
22
|
-
Handy alias to `cd' to a gem directory:
|
23
|
-
|
24
|
-
function cdrg {
|
25
|
-
if [ $# -eq 0 ]; then
|
26
|
-
cd `gem env gemdir`/gems
|
27
|
-
elif gem info --exactly-one $@ > /dev/null; then
|
28
|
-
local dir=`gem info -f '%path' $@`
|
29
|
-
if [ -d $dir/lib ]; then
|
30
|
-
cd $dir/lib
|
31
|
-
else
|
32
|
-
cd $dir
|
33
|
-
fi
|
34
|
-
fi
|
35
|
-
}
|
36
|
-
|
37
|
-
$ cdrg rails # oops!
|
38
|
-
2 matching gems:
|
39
|
-
rails 2.3.3
|
40
|
-
rails 2.3.4
|
41
|
-
$ cdrg rails 4 # only 2.3.4 contains '4'
|
42
|
-
$ pwd
|
43
|
-
/usr/lib/ruby/gems/1.8/gems/rails-2.3.4/lib
|
44
|
-
|
45
|
-
== Contributing
|
46
|
-
|
47
|
-
* Bug reports: http://github.com/oggy/gem_info/issues
|
48
|
-
* Source: http://github.com/oggy/gem_info
|
49
|
-
* Patches: Fork on Github, send pull request.
|
50
|
-
* Ensure patch includes tests.
|
51
|
-
* Leave the version alone, or bump it in a separate commit.
|
52
|
-
|
53
|
-
== Copyright
|
54
|
-
|
55
|
-
Copyright (c) 2009 George Ogata. See LICENSE for details.
|
data/VERSION
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
0.0.1
|
data/gem_info.gemspec
DELETED
@@ -1,70 +0,0 @@
|
|
1
|
-
# Generated by jeweler
|
2
|
-
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
|
4
|
-
# -*- encoding: utf-8 -*-
|
5
|
-
|
6
|
-
Gem::Specification.new do |s|
|
7
|
-
s.name = %q{gem_info}
|
8
|
-
s.version = "0.0.1"
|
9
|
-
|
10
|
-
s.required_rubygems_version = Gem::Requirement.new(">= 1.3.2") if s.respond_to? :required_rubygems_version=
|
11
|
-
s.authors = ["George Ogata"]
|
12
|
-
s.date = %q{2010-03-17}
|
13
|
-
s.description = %q{A rubygems plugin which adds an `info' command which prints
|
14
|
-
information about gems.
|
15
|
-
|
16
|
-
Unlike the built-in gem commands, it allows fuzzy matching on gem
|
17
|
-
names and versions by default, and allows precise formatting of the
|
18
|
-
output, making it easy on the command line and in scripts.
|
19
|
-
}
|
20
|
-
s.email = %q{george.ogata@gmail.com}
|
21
|
-
s.extra_rdoc_files = [
|
22
|
-
"LICENSE",
|
23
|
-
"README.rdoc"
|
24
|
-
]
|
25
|
-
s.files = [
|
26
|
-
".document",
|
27
|
-
".gitignore",
|
28
|
-
"DESCRIPTION",
|
29
|
-
"LICENSE",
|
30
|
-
"README.rdoc",
|
31
|
-
"Rakefile",
|
32
|
-
"VERSION",
|
33
|
-
"gem_info.gemspec",
|
34
|
-
"lib/gem_info.rb",
|
35
|
-
"lib/gem_info/errors.rb",
|
36
|
-
"lib/gem_info/fuzzy_matcher.rb",
|
37
|
-
"lib/gem_info/runner.rb",
|
38
|
-
"lib/rubygems_plugin.rb",
|
39
|
-
"spec/fuzzy_matcher_spec.rb",
|
40
|
-
"spec/runner_spec.rb",
|
41
|
-
"spec/spec_helper.rb"
|
42
|
-
]
|
43
|
-
s.homepage = %q{http://github.com/oggy/gem_info}
|
44
|
-
s.rdoc_options = ["--charset=UTF-8"]
|
45
|
-
s.require_paths = ["lib"]
|
46
|
-
s.rubygems_version = %q{1.3.6}
|
47
|
-
s.summary = %q{Print information about gems.}
|
48
|
-
s.test_files = [
|
49
|
-
"spec/fuzzy_matcher_spec.rb",
|
50
|
-
"spec/runner_spec.rb",
|
51
|
-
"spec/spec_helper.rb"
|
52
|
-
]
|
53
|
-
|
54
|
-
if s.respond_to? :specification_version then
|
55
|
-
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
56
|
-
s.specification_version = 3
|
57
|
-
|
58
|
-
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
59
|
-
s.add_development_dependency(%q<rspec>, [">= 0"])
|
60
|
-
s.add_development_dependency(%q<mocha>, [">= 0"])
|
61
|
-
else
|
62
|
-
s.add_dependency(%q<rspec>, [">= 0"])
|
63
|
-
s.add_dependency(%q<mocha>, [">= 0"])
|
64
|
-
end
|
65
|
-
else
|
66
|
-
s.add_dependency(%q<rspec>, [">= 0"])
|
67
|
-
s.add_dependency(%q<mocha>, [">= 0"])
|
68
|
-
end
|
69
|
-
end
|
70
|
-
|