fuubar 2.4.1 → 2.5.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f33c75eecd40f56ed951ba0271450860b3ebebbb0bbd1176f77a78de206b28f6
4
- data.tar.gz: 185aa80a3b147b9c6178871c09474e7ffe9231219e3b4cb48cdf0262678dfcfb
3
+ metadata.gz: e6d29a56ef25f3e30985d225989de0c99591fd954ba9dec2fa55e86a1422fe27
4
+ data.tar.gz: 26b2530b3da3c0cd3a9234d8c150a47a2e8e07c9561752a8af2402596be846c7
5
5
  SHA512:
6
- metadata.gz: d8d30b539b96fe08156290d6ac407cea29a062e1b29eaf8fa39e041a8844abbb221775a0678e6644c0b1568b8996a5995ed84d23fc11729b0613b102af712d5c
7
- data.tar.gz: e6f41f9692280dae28a8c44daf08f9df19a59b083579ea195d29a166d63bf68a88816137d7d9b17f4733556e2087756b04363990cd1a1f2aa5387db0959f99ec
6
+ metadata.gz: 305f30a7d08e154fd0cdcc19fe04ac5870e9c8419727f99e8d8b24e3d4582d07e7aad8ddfff38896b2118a0306c9153d36350d67e0c1a501a3e5304d863c6ea5
7
+ data.tar.gz: 0b276bc8db278f6ee01941106efd69d44a0a514f0e057f3b277cb57d2db10d1609adf2b31674a9c979716b08dd47b17e20c9e6bf906e26d3ede013fa547234d5
Binary file
data.tar.gz.sig CHANGED
Binary file
data/README.md CHANGED
@@ -94,23 +94,54 @@ RSpec.configure do |config|
94
94
  end
95
95
  ```
96
96
 
97
- ### Disabling Auto-Refresh ###
97
+ ### Enabling Auto-Refresh ###
98
98
 
99
- By default fuubar will automatically refresh the bar (and therefore the ETA)
100
- every second. Unfortunately this doesn't play well with things like debuggers.
101
- When you're debugging, having a bar show up every second is undesireable.
102
- [Pry][pry] gives us hooks so that we can automatically disable the refresh when
103
- it's used. Unfortunately [byebug][byebug] does not and disabling the bar must be
104
- done manually.
99
+ By default fuubar refreshes the bar only between each spec.
100
+ You can enable an auto-refresh feature that will keep refreshing the bar (and
101
+ therefore the ETA) every second.
102
+ You can enable the feature as follows:
105
103
 
106
- #### Example ####
107
104
 
108
105
  ```ruby
109
106
  # spec/spec_helper.rb
110
107
 
111
108
  RSpec.configure do |config|
112
- config.fuubar_auto_refresh = false
109
+ config.fuubar_auto_refresh = true
110
+ end
111
+ ```
112
+
113
+ #### Undesirable effects
114
+
115
+ Unfortunately this option doesn't play well with things like debuggers, as
116
+ having a bar show up every second would be undesireable (which is why the
117
+ feature is disabled by default). Depending on what you are using, you may be
118
+ given ways to work around this problem.
119
+
120
+ ##### Pry
121
+
122
+ [Pry][pry] provides hooks that can be used to disable fuubar during a debugging
123
+ session, you could for example add the following to your spec helper:
124
+
125
+ ```ruby
126
+ # spec/spec_helper.rb
127
+
128
+ Pry.config.hooks.add_hook(:before_session, :disable_fuubar_auto_refresh) do |_output, _binding, _pry|
129
+ RSpec.configuration.fuubar_auto_refresh = false
113
130
  end
131
+
132
+ Pry.config.hooks.add_hook(:after_session, :restore_fuubar_auto_refresh) do |_output, _binding, _pry|
133
+ RSpec.configuration.fuubar_auto_refresh = true
134
+ end
135
+ ```
136
+
137
+ ##### Byebug
138
+
139
+ Unfortunately [byebug][byebug] does not provide hooks, so your best bet is to
140
+ disable auto-refresh manually before calling `byebug`.
141
+
142
+ ```ruby
143
+ RSpec.configuration.fuubar_auto_refresh = false
144
+ byebug
114
145
  ```
115
146
 
116
147
  Security
@@ -6,18 +6,9 @@ require 'ruby-progressbar'
6
6
  require 'fuubar/output'
7
7
 
8
8
  RSpec.configuration.add_setting :fuubar_progress_bar_options, :default => {}
9
- RSpec.configuration.add_setting :fuubar_auto_refresh, :default => true
9
+ RSpec.configuration.add_setting :fuubar_auto_refresh, :default => false
10
10
  RSpec.configuration.add_setting :fuubar_output_pending_results, :default => true
11
11
 
12
- if Object.const_defined?('Pry')
13
- Pry.
14
- config.
15
- hooks.
16
- add_hook(:when_started, :fuubar_kill_refresh) do |_target, _opt, _|
17
- RSpec.configuration.fuubar_auto_refresh = false
18
- end
19
- end
20
-
21
12
  class Fuubar < RSpec::Core::Formatters::BaseTextFormatter
22
13
  DEFAULT_PROGRESS_BAR_OPTIONS = { :format => ' %c/%C |%w>%i| %e ' }.freeze
23
14
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fuubar
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.4.1
4
+ version: 2.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nicholas Evans
@@ -13,31 +13,31 @@ cert_chain:
13
13
  - |
14
14
  -----BEGIN CERTIFICATE-----
15
15
  MIIEdjCCAt6gAwIBAgIBATANBgkqhkiG9w0BAQsFADAyMTAwLgYDVQQDDCdhY2Nv
16
- dW50c19ydWJ5Z2Vtcy9EQz10aGVrb21wYW5lZS9EQz1jb20wHhcNMTgwODAzMjEz
17
- NjUzWhcNMTkwODAzMjEzNjUzWjAyMTAwLgYDVQQDDCdhY2NvdW50c19ydWJ5Z2Vt
16
+ dW50c19ydWJ5Z2Vtcy9EQz10aGVrb21wYW5lZS9EQz1jb20wHhcNMTkwOTIwMDY1
17
+ NjU5WhcNMjAwOTE5MDY1NjU5WjAyMTAwLgYDVQQDDCdhY2NvdW50c19ydWJ5Z2Vt
18
18
  cy9EQz10aGVrb21wYW5lZS9EQz1jb20wggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAw
19
- ggGKAoIBgQDR6ma5Z4B2Qz+ykVUKn2CoWwoJ3vStZLDNc6nIOUTUDFS5rg43XwwB
20
- nnHCLhHZ9QeNflBpJObMwIUwDqxfZoxhmEILzUfv/yuoBj90zmnf7K2mmsPuT44a
21
- aTyZjYGid+yyTbzIpR4CCBHyvGNVm9ss64C2XXPNXrlLO3eAxgB9zNYkxOeJatZp
22
- d1h5FZIkAqgw7rx65W+e4HUSNnUvzUmZKoO0u/yMlnc4NcK05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uqQrZEpYIn23x
35
+ LQJp2syl3zPKRuR9SowlWW91gYxRv1iOv4Skn0ct2QOOY4nfczkAXZ++QQXdpBY8
36
+ bhD2gZ4C5v23/Xg0mBvEdTtsXr7EPFF4ki7HJPHjcw2qi+VlXAUDvjpEOV3fJfdr
37
+ ueUkus2RBlHNjmQ1bzVommjkFSE0E4L0u8lrU7axdH6XsGt2VOx+m4qyPeU/seN1
38
+ UTOujiMrrUIxVx+OYc1H9cGSvTGEualhzuCTUG17pW5mrck5LrVc/vq2
39
39
  -----END CERTIFICATE-----
40
- date: 2019-07-03 00:00:00.000000000 Z
40
+ date: 2019-10-28 00:00:00.000000000 Z
41
41
  dependencies:
42
42
  - !ruby/object:Gem::Dependency
43
43
  name: rspec-core
metadata.gz.sig CHANGED
Binary file