auto_reloader 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 99632ea44296a699ee7b09919b575b5170664b2f
4
- data.tar.gz: 098842b34c4c6b1e88ac52cb643b699e808cfa3d
3
+ metadata.gz: daf88a04cf59b1e864b0b1875ce69a6b8acda29e
4
+ data.tar.gz: 6076dd6f16793cbb3eaf4af78390deb25d24adbb
5
5
  SHA512:
6
- metadata.gz: c8828483df4f252c89d444e0a2ad5fba7e9c69b79c502a5ecf7a493046993aee31b7530bfabaeda441f5943f387d2acf161ee40b49d97688bcd4bc1ef3e2f6e1
7
- data.tar.gz: 085e65d7b86d11b772d8c2c7ceee53c1bbf90dbc816a710d6de88a12d97effac035c4d87fcc9a5e772bbbc0f2621c675452cc8ee56f8d58dad316ff142a5543b
6
+ metadata.gz: 240f67f555b5d013adb705d525307773787677a67b84f0fd4cbc5f3c5930f541593b0008c306995b7b27f40c5d31aa491c867c8572490e8a7afe29669b0a083b
7
+ data.tar.gz: 2f0cd75e06b2d8da9ea827703890f96fd324447988551d9af3612dc9ca930edff209a2f4eb5ce64ab4d2a73200f283d111f0061d53d5e4b0a334f4c4db0ae1d5
data/lib/auto_reloader.rb CHANGED
@@ -56,22 +56,23 @@ class AutoReloader
56
56
  end
57
57
 
58
58
  def require(path, &block)
59
- was_required = error = false
59
+ was_required = false
60
+ error = nil
60
61
  @require_lock.synchronize do
61
62
  @top_level_consts_stack << Set.new
62
63
  old_consts = Object.constants
63
64
  prev_consts = new_top_level_constants = nil
64
65
  begin
65
66
  was_required = yield
66
- rescue Exception
67
- error = true
67
+ rescue Exception => e
68
+ error = e
68
69
  ensure
69
70
  prev_consts = @top_level_consts_stack.pop
70
71
  return false if !error && !was_required # was required already, do nothing
71
72
 
72
73
  new_top_level_constants = Object.constants - old_consts - prev_consts.to_a
73
74
 
74
- (new_top_level_constants.each{|c| safe_remove_constant c }; raise) if error
75
+ (new_top_level_constants.each{|c| safe_remove_constant c }; raise error) if error
75
76
 
76
77
  @top_level_consts_stack.each{|c| c.merge new_top_level_constants }
77
78
 
@@ -1,3 +1,3 @@
1
1
  class AutoReloader
2
- VERSION = '0.2.3'
2
+ VERSION = '0.2.4'
3
3
  end
metadata CHANGED
@@ -1,72 +1,72 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: auto_reloader
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rodrigo Rosenfeld Rosas
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-08-04 00:00:00.000000000 Z
11
+ date: 2016-08-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
+ name: bundler
14
15
  requirement: !ruby/object:Gem::Requirement
15
16
  requirements:
16
17
  - - "~>"
17
18
  - !ruby/object:Gem::Version
18
19
  version: '1.11'
19
- name: bundler
20
- prerelease: false
21
20
  type: :development
21
+ prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.11'
27
27
  - !ruby/object:Gem::Dependency
28
+ name: rake
28
29
  requirement: !ruby/object:Gem::Requirement
29
30
  requirements:
30
31
  - - "~>"
31
32
  - !ruby/object:Gem::Version
32
33
  version: '10.0'
33
- name: rake
34
- prerelease: false
35
34
  type: :development
35
+ prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
41
  - !ruby/object:Gem::Dependency
42
+ name: rspec
42
43
  requirement: !ruby/object:Gem::Requirement
43
44
  requirements:
44
45
  - - "~>"
45
46
  - !ruby/object:Gem::Version
46
47
  version: '3.0'
47
- name: rspec
48
- prerelease: false
49
48
  type: :development
49
+ prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '3.0'
55
55
  - !ruby/object:Gem::Dependency
56
+ name: listen
56
57
  requirement: !ruby/object:Gem::Requirement
57
58
  requirements:
58
59
  - - "~>"
59
60
  - !ruby/object:Gem::Version
60
61
  version: '3.0'
61
- name: listen
62
- prerelease: false
63
62
  type: :development
63
+ prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: '3.0'
69
- description:
69
+ description:
70
70
  email:
71
71
  - rr.rosas@gmail.com
72
72
  executables: []
@@ -89,7 +89,7 @@ homepage: https://github.com/rosenfeld/auto_reloader
89
89
  licenses:
90
90
  - MIT
91
91
  metadata: {}
92
- post_install_message:
92
+ post_install_message:
93
93
  rdoc_options: []
94
94
  require_paths:
95
95
  - lib
@@ -104,9 +104,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
104
104
  - !ruby/object:Gem::Version
105
105
  version: '0'
106
106
  requirements: []
107
- rubyforge_project:
108
- rubygems_version: 2.6.4
109
- signing_key:
107
+ rubyforge_project:
108
+ rubygems_version: 2.5.1
109
+ signing_key:
110
110
  specification_version: 4
111
111
  summary: A transparent code reloader.
112
112
  test_files: []