midwire_common 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +4 -0
- data/README.md +1 -1
- data/lib/midwire_common/version.rb +1 -1
- data/lib/tasks/version.rake +12 -7
- data/midwire_common.gemspec +2 -2
- data/spec/lib/midwire_common/string_spec.rb +2 -0
- metadata +6 -6
data/CHANGELOG
CHANGED
data/README.md
CHANGED
data/lib/tasks/version.rake
CHANGED
@@ -65,16 +65,21 @@ namespace :version do
|
|
65
65
|
private
|
66
66
|
|
67
67
|
def version_file_path
|
68
|
-
|
68
|
+
split = PROJECT_NAME.split('-')
|
69
|
+
"#{PROJECT_ROOT}/lib/#{split.join('/')}/version.rb"
|
69
70
|
end
|
70
71
|
|
71
|
-
def
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
72
|
+
def module_name
|
73
|
+
if PROJECT_NAME.match(/-/)
|
74
|
+
PROJECT_NAME.split('-').map {|e| e.capitalize}.join('::')
|
75
|
+
elsif PROJECT_NAME.match(/_/)
|
76
|
+
PROJECT_NAME.split('_').map {|e| e.capitalize}.join
|
77
|
+
else
|
78
|
+
PROJECT_NAME.capitalize
|
77
79
|
end
|
80
|
+
end
|
81
|
+
|
82
|
+
def read_version
|
78
83
|
load version_file_path
|
79
84
|
text = eval("#{module_name}::VERSION")
|
80
85
|
major, minor, patch = text.split('.')
|
data/midwire_common.gemspec
CHANGED
@@ -5,8 +5,8 @@ Gem::Specification.new do |gem|
|
|
5
5
|
gem.authors = ["Chris Blackburn"]
|
6
6
|
gem.email = ["chris@midwiretech.com"]
|
7
7
|
gem.description = %q{A useful Ruby library for the Midwire development team}
|
8
|
-
gem.summary = %q{
|
9
|
-
gem.homepage = "
|
8
|
+
gem.summary = %q{Midwire Ruby Library}
|
9
|
+
gem.homepage = "https://github.com/midwire/midwire_common"
|
10
10
|
|
11
11
|
gem.files = `git ls-files`.split($\)
|
12
12
|
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: midwire_common
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-12-31 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rspec
|
@@ -183,7 +183,7 @@ files:
|
|
183
183
|
- spec/lib/midwire_common/time_spec.rb
|
184
184
|
- spec/lib/midwire_common/time_tool_spec.rb
|
185
185
|
- spec/spec_helper.rb
|
186
|
-
homepage:
|
186
|
+
homepage: https://github.com/midwire/midwire_common
|
187
187
|
licenses: []
|
188
188
|
post_install_message:
|
189
189
|
rdoc_options: []
|
@@ -197,7 +197,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
197
197
|
version: '0'
|
198
198
|
segments:
|
199
199
|
- 0
|
200
|
-
hash:
|
200
|
+
hash: -4180799989477412744
|
201
201
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
202
202
|
none: false
|
203
203
|
requirements:
|
@@ -206,13 +206,13 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
206
206
|
version: '0'
|
207
207
|
segments:
|
208
208
|
- 0
|
209
|
-
hash:
|
209
|
+
hash: -4180799989477412744
|
210
210
|
requirements: []
|
211
211
|
rubyforge_project:
|
212
212
|
rubygems_version: 1.8.23
|
213
213
|
signing_key:
|
214
214
|
specification_version: 3
|
215
|
-
summary:
|
215
|
+
summary: Midwire Ruby Library
|
216
216
|
test_files:
|
217
217
|
- spec/lib/midwire_common/array_spec.rb
|
218
218
|
- spec/lib/midwire_common/data_file_cache_spec.rb
|