maccman-bowline 0.3.7 → 0.3.9

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/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.7
1
+ 0.3.9
data/bowline.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{bowline}
5
- s.version = "0.3.7"
5
+ s.version = "0.3.9"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Alex MacCaw"]
@@ -49,7 +49,6 @@ Gem::Specification.new do |s|
49
49
  "lib/bowline/dependencies/lib/dependencies/dependency.rb",
50
50
  "lib/bowline/dependencies/lib/dependencies/reader.rb",
51
51
  "lib/bowline/dependencies/lib/dependencies/repository.rb",
52
- "lib/bowline/dependencies/lib/ext/common.rb",
53
52
  "lib/bowline/dependencies/lib/ext/rubygems.rb",
54
53
  "lib/bowline/dependencies/lib/template/app_script.rb",
55
54
  "lib/bowline/dependencies/spec/spec.opts",
@@ -183,10 +183,11 @@ module Bowline
183
183
  options = {
184
184
  :lib => dep.name
185
185
  }.merge(dep.options)
186
-
186
+
187
+ next unless options[:lib]
187
188
  begin
188
- activated = gem(dep.name, *dep.versions)
189
- require(options[:lib]) if activated && options[:lib]
189
+ gem(dep.name, *dep.versions)
190
+ require(options[:lib])
190
191
  rescue LoadError => e
191
192
  puts "was unable to require #{dep.name} as '#{options[:lib]}'
192
193
  Reason: #{e.class.name} error raised with message: #{e.message}"
@@ -2,7 +2,7 @@ module Bowline
2
2
  module Version #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 3
5
- TINY = 7
5
+ TINY = 9
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: maccman-bowline
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.7
4
+ version: 0.3.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alex MacCaw
@@ -75,7 +75,6 @@ files:
75
75
  - lib/bowline/dependencies/lib/dependencies/dependency.rb
76
76
  - lib/bowline/dependencies/lib/dependencies/reader.rb
77
77
  - lib/bowline/dependencies/lib/dependencies/repository.rb
78
- - lib/bowline/dependencies/lib/ext/common.rb
79
78
  - lib/bowline/dependencies/lib/ext/rubygems.rb
80
79
  - lib/bowline/dependencies/lib/template/app_script.rb
81
80
  - lib/bowline/dependencies/spec/spec.opts
@@ -1,68 +0,0 @@
1
- # This was added via Merb's bundler
2
-
3
- require "rubygems"
4
- require "rubygems/source_index"
5
-
6
- module Gem
7
- BUNDLED_SPECS = File.join(Dir.pwd, "gems", "specifications")
8
- MAIN_INDEX = Gem::SourceIndex.from_gems_in(BUNDLED_SPECS)
9
- FALLBACK_INDEX = Gem::SourceIndex.from_installed_gems
10
-
11
- def self.source_index
12
- MultiSourceIndex.new
13
- end
14
-
15
- def self.searcher
16
- MultiPathSearcher.new
17
- end
18
-
19
- class ArbitrarySearcher < GemPathSearcher
20
- def initialize(source_index)
21
- @source_index = source_index
22
- super()
23
- end
24
-
25
- def init_gemspecs
26
- @source_index.map { |_, spec| spec }.sort { |a,b|
27
- (a.name <=> b.name).nonzero? || (b.version <=> a.version)
28
- }
29
- end
30
- end
31
-
32
- class MultiPathSearcher
33
- def initialize
34
- @main_searcher = ArbitrarySearcher.new(MAIN_INDEX)
35
- @fallback_searcher = ArbitrarySearcher.new(FALLBACK_INDEX)
36
- end
37
-
38
- def find(path)
39
- try = @main_searcher.find(path)
40
- return try if try
41
- @fallback_searcher.find(path)
42
- end
43
-
44
- def find_all(path)
45
- try = @main_searcher.find_all(path)
46
- return try unless try.empty?
47
- @fallback_searcher.find_all(path)
48
- end
49
- end
50
-
51
- class MultiSourceIndex
52
- # Used by merb.thor to confirm; not needed when MSI is in use
53
- def load_gems_in(*args)
54
- end
55
-
56
- def search(*args)
57
- try = MAIN_INDEX.search(*args)
58
- return try unless try.empty?
59
- FALLBACK_INDEX.search(*args)
60
- end
61
-
62
- def find_name(*args)
63
- try = MAIN_INDEX.find_name(*args)
64
- return try unless try.empty?
65
- FALLBACK_INDEX.find_name(*args)
66
- end
67
- end
68
- end