modernizer 0.0.1 → 0.0.2

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.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MDlmNWRiNjc1OGY4N2JiYzEwMWYxOTMwZjRlYThlODA1YWQ3YWQ4Ng==
4
+ NmViZTA5Mzk5YjMzNThhNzBlMmNkMTIxODliYzhhNmJhZDg3YTgwNQ==
5
5
  data.tar.gz: !binary |-
6
- NDM4MGNlOTU0ZGQ1MGJkYTMxMDBjYjI3NzQ0NjhiNjZmNzQ5ODg3Mw==
6
+ MjdiOTk2ZGU0ZmMyM2FmNzc1MTIxZWQ5ZWFhOWVmZWY0YzZhN2I5Yg==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- NTk0MmU2MDMzMTFjZDc3NmFhMjA2YTc5OWRhNjZkZTQ3OGEyMzc3YWIxYjE3
10
- Nzg4NDViMmUwYzMwZWZmYThmYTc5NDljOTAzODI3NTlhYTM3YTZiN2U1Y2Q0
11
- NGJlZmUxOWI5ZjM3MjVmZDk1M2NkYzJiMWU5MmZiMWNkYzM0NWI=
9
+ NWVlY2Y5OTVmZWUwYzI2N2E2NzIzZDBkMmJhMzM5YjMwN2NjMjU2ODhjNGZl
10
+ Y2QwZDczYWFmNWRlNzNhNWUxMzIyZTI3ODRkMzhjNmE0OGVjMTJhOTEyYTkx
11
+ N2YyMTJmZTJmYzk1ZjExYjRkMGNhODhjNjZjMzRmYjZiMmFkYTU=
12
12
  data.tar.gz: !binary |-
13
- MWMwMDc3MTI5YmIzNDc0NzE4MzA3MmIxNTcyZjIwMmFmNTYxMjUxZmFkNjY3
14
- OWUzYzlmYTlmNjkzOTU5N2YyOWYzNDc4MzM4YTM3MWQ0MGUwZDg2MDE0ZDA1
15
- OWFhM2ZiZjJkNDU3YjQzZDhmNTk4NmQwZmIxOTMyN2E4ODZmNTQ=
13
+ Y2Q4OGM3YjA3Y2UzM2U3ZTZhYmE3YmYxZmVjOWE3YjYxYjhmMGVlM2JlMmJl
14
+ NDk1MDViNWZkOTk1ZjVhNjUzNWNkZjA1NWFkYTBkYTIzMjY4M2E4OGMxYjUz
15
+ NjNlZGY1ZWIyM2ZhMTNlNGE3ZWQwOTRkNmM1N2Y0ZGZiOWNiZmQ=
data/README.md CHANGED
@@ -26,7 +26,7 @@ Modernizer.new do
26
26
  end
27
27
 
28
28
  modernize '1.2.1' do
29
- add('foo') { "#{@body['hello']}-bar" }
29
+ add('foo') { "#{@hash['hello']}-bar" }
30
30
  end
31
31
 
32
32
  modernize '1.2.3' do
data/lib/modernizer.rb CHANGED
@@ -38,14 +38,20 @@ module Modernize
38
38
 
39
39
  raise StandardError.new('calculated version is not valid') unless Gem::Version.correct?(struct_version)
40
40
 
41
+ # gets a list of the potential versions
42
+ #
43
+ migration_versions = @migrations.translations.keys
44
+ migration_versions.delete(:first)
45
+ migration_versions.delete(:last)
46
+
41
47
  # get the first and last translations
42
48
  #
43
- firsts = @migrations.translations.delete(:first)
44
- lasts = @migrations.translations.delete(:last)
49
+ firsts = @migrations.translations[:first]
50
+ lasts = @migrations.translations[:last]
45
51
 
46
- # gets a list of the potential versions and then sorts them
52
+ # sorts the versions
47
53
  #
48
- migration_versions = @migrations.translations.keys.sort! do |x,y|
54
+ migration_versions.sort! do |x,y|
49
55
  Gem::Version.new(x) <=> Gem::Version.new(y)
50
56
  end
51
57
 
@@ -1,3 +1,3 @@
1
1
  module Modernizer
2
- VERSION = '0.0.1'
2
+ VERSION = '0.0.2'
3
3
  end
data/modernizer.gemspec CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
10
10
  spec.email = ['rtjoseph11@gmail.com']
11
11
  spec.description = %q{convert hashes based on translations associated with versions}
12
12
  spec.summary = %q{see description}
13
- spec.homepage = ''
13
+ spec.homepage = 'https://github.com/rtjoseph11/modernizer'
14
14
  spec.license = 'MIT'
15
15
 
16
16
  spec.files = `git ls-files`.split($/)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: modernizer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tucker Joseph
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-09-04 00:00:00.000000000 Z
11
+ date: 2013-09-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -87,7 +87,7 @@ files:
87
87
  - modernizer.gemspec
88
88
  - spec/modernizer_spec.rb
89
89
  - spec/spec_tasks.rb
90
- homepage: ''
90
+ homepage: https://github.com/rtjoseph11/modernizer
91
91
  licenses:
92
92
  - MIT
93
93
  metadata: {}