guard 2.0.5 → 2.1.0

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: f735478a21204cd377abb592bf32d7589c74f42f
4
- data.tar.gz: a65a5ba790394d770b2fa272e634d80946859b44
3
+ metadata.gz: 6500e7d2927db23543d36ec1dc5574f0678e68b6
4
+ data.tar.gz: ebb55bd7d63bacfd3a927bbe7060ad5c4eaecd5c
5
5
  SHA512:
6
- metadata.gz: 335bd61ca3593cf9439fd0b56b1797c492d0323dff3fc88987a33fcb7d18e28b85bac79d130827a11598c2e881280e998dee6025d51fd2b7b55ffdbed67ab061
7
- data.tar.gz: cff4e0d3d466dfb0e317751f588ef42b153965695bd0aa003c8ecceb0e44b4789c127d45d35be16129db0476edc2a7240a8fc5409ecbed45b31e4679e27a5b79
6
+ metadata.gz: 071db2999a5902a860dfd4c25635dee9a72c309fe92246f0998072ed4904593df288c4c36fba61703b1f1a5e63a7688f497bb706a80cdb1d5defa3d7d5bd5aa5
7
+ data.tar.gz: b8c9f33e9272a26a29f25e293963a48107c1f0f595cecfaf43fa6037b93ebf8560e1848598cadb7b7e15d50f8d2729576bbb5c5b3301e993373c0f04b8a38e45
data/README.md CHANGED
@@ -330,7 +330,7 @@ $ bundle exec guard notifiers
330
330
  +-------------------+-----------+------+------------------------+-------------------+
331
331
  ```
332
332
 
333
- This shows if a notifier is available on the current system, it it's being used and the
333
+ This shows if a notifier is available on the current system, if it's being used and the
334
334
  current options (which reflects your custom options merged into the default options).
335
335
 
336
336
  Interactions
@@ -270,7 +270,7 @@ module Guard
270
270
  #
271
271
  def _scope_for_prompt
272
272
  [:plugins, :groups].each do |scope_name|
273
- return _join_scope_for_prompt(scope_name) unless ::Guard.scope[scope_name].empty?
273
+ return "#{_join_scope_for_prompt(scope_name)} " unless ::Guard.scope[scope_name].empty?
274
274
  end
275
275
 
276
276
  ''
@@ -289,13 +289,16 @@ module Guard
289
289
  proc do |target_self, nest_level, pry|
290
290
  history = pry.input_array.size
291
291
  process = ::Guard.listener.paused? ? 'pause' : 'guard'
292
- clip = Pry.view_clip(target_self)
293
292
  level = ":#{ nest_level }" unless nest_level.zero?
294
293
 
295
- "[#{ history }] #{ _scope_for_prompt }#{ process }(#{ clip })#{ level }#{ ending_char } "
294
+ "[#{ history }] #{ _scope_for_prompt }#{ process }(#{ _clip_name(target_self) })#{ level }#{ ending_char } "
296
295
  end
297
296
  end
298
297
 
298
+ def _clip_name(target)
299
+ Pry.view_clip(target)
300
+ end
301
+
299
302
  # Detects whether or not the stty command exists
300
303
  # on the user machine.
301
304
  #
@@ -83,7 +83,7 @@ module Guard
83
83
  # @option opts [String] image the path to the notification image
84
84
  # @option opts [Boolean] change_color whether to show a color
85
85
  # notification
86
- # @option opts [String] color_location the location where to draw the
86
+ # @option opts [String,Array] color_location the location where to draw the
87
87
  # color notification
88
88
  # @option opts [Boolean] display_message whether to display a message
89
89
  # or not
@@ -93,10 +93,12 @@ module Guard
93
93
  opts.delete(:image)
94
94
 
95
95
  if opts.fetch(:change_color, DEFAULTS[:change_color])
96
- color_location = opts.fetch(:color_location, DEFAULTS[:color_location])
96
+ color_locations = Array(opts.fetch(:color_location, DEFAULTS[:color_location]))
97
97
  color = tmux_color(opts[:type], opts)
98
98
 
99
- _run_client "set #{ color_location } #{ color }"
99
+ color_locations.each do |color_location|
100
+ _run_client "set #{ color_location } #{ color }"
101
+ end
100
102
  end
101
103
 
102
104
  if opts.fetch(:display_message, DEFAULTS[:display_message])
@@ -1,3 +1,3 @@
1
1
  module Guard
2
- VERSION = '2.0.5'
2
+ VERSION = '2.1.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guard
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.5
4
+ version: 2.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thibaud Guillaume-Gentil
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-10-11 00:00:00.000000000 Z
11
+ date: 2013-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ~>
32
32
  - !ruby/object:Gem::Version
33
- version: '2.0'
33
+ version: '2.1'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ~>
39
39
  - !ruby/object:Gem::Version
40
- version: '2.0'
40
+ version: '2.1'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: pry
43
43
  requirement: !ruby/object:Gem::Requirement