listen 2.9.0 → 2.10.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: 605396a439fbf1b2b5df82537a68379c6179fec2
4
- data.tar.gz: c1500d284d1f2014b355b24a1b93e06a6928e7f8
3
+ metadata.gz: b7d761e41830d7a1ab26c12f681c86434f8f3ca8
4
+ data.tar.gz: bb0360cd61be2b710ca0964af23e569204ce52fa
5
5
  SHA512:
6
- metadata.gz: 02a60070b24579a8aa612605bdac0a119b3c47bac007f3145f2e6c6b66a033f1a4b7cf8d46f63fe06fbefe4d79aa32651fe16b809b23e774eefcd86cd04450ba
7
- data.tar.gz: 48910b3a4df30ef041339d6176da6b897d207b92a26e3c2ed5e9f142dabe70c6cd3a873b6a56cc0b81bbd1e61eaf79a2487d270122e5392497ccf056bc2e2e2b
6
+ metadata.gz: 990bf729b6f8fc4208b3677047464665434538f2fc4c64dccdff4dd2d0da586477f61c593e3bcb1416f809072cb7a7d69045b9871a087a6365a352e1c8cb0903
7
+ data.tar.gz: 9f8ed8e2f7a63e68b4d59beb2414ff9818d1ae539b1e58e9fdc6214e11400fb3945a6b3a35fd4452c0e88fb702e6854a2580e38ede78f96a2cf8e69d9f18fe76
data/README.md CHANGED
@@ -204,7 +204,7 @@ gem 'wdm', '>= 0.1.0' if Gem.win_platform?
204
204
 
205
205
  ### On \*BSD
206
206
 
207
- If your are on \*BSD you can try to use the [`rb-kqueue`](https://github.com/mat813/rb-kqueue) instead of polling.
207
+ If your are on \*BSD you can try to use the [`rb-kqueue`](https://github.com/mat813/rb-kqueue) adapter instead of polling.
208
208
 
209
209
  Please add the following to your Gemfile:
210
210
 
@@ -249,7 +249,9 @@ When in doubt, LISTEN_GEM_DEBUGGING=2 can help discover the actual events and ti
249
249
 
250
250
  ## Forwarding file events over TCP
251
251
 
252
- Listen is capable of forwarding file events over the network using a messaging protocol. This can be useful for virtualized development environments when file events are unavailable, as is the case with shared folders in VMs. [Vagrant](https://github.com/mitchellh/vagrant) uses Listen in it's rsync-auto mode to solve this issue.
252
+ Listen is capable of forwarding file events over the network using a messaging protocol. This can be useful for virtualized development environments when file events are unavailable, as is the case with shared folders in VMs.
253
+
254
+ [Vagrant](https://github.com/mitchellh/vagrant) uses Listen in it's rsync-auto mode to solve this issue.
253
255
 
254
256
  To broadcast events over TCP programmatically, use the `forward_to` option with an address - just a port or a hostname/port combination:
255
257
 
@@ -265,10 +267,13 @@ sleep
265
267
  As a convenience, the `listen` script is supplied which listens to a directory and forwards the events to a network address
266
268
 
267
269
  ```bash
268
- listen -f "10.0.0.2:4000"
269
- listen -v -d "/projects/my_project" -f "10.0.0.2:4000"
270
+ listen -f "10.0.0.2:4000" # changes in current directory are sent as absolute paths
271
+ listen -r -f "10.0.0.2:4000" # changes in current directory are sent as relative paths
272
+ listen -v -d "/projects/my_project" -f "10.0.0.2:4000" # changes in given directory are also shown
270
273
  ```
271
274
 
275
+ *NOTE: if you are using a gem like `guard` and the paths on host and guest are not exactly the same, you'll generally want to use the `-r` option for relative paths*
276
+
272
277
  To connect to a broadcasting listener as a recipient, specify its address using `Listen.on`:
273
278
 
274
279
  ```ruby
@@ -93,6 +93,8 @@ module Listen
93
93
 
94
94
  def _watch_file(path, queue)
95
95
  queue.watch_file(path, *options.events, &@callback)
96
+ rescue Errno::ENOENT => e
97
+ _log :warn, "kqueue: watch file failed: #{e.message}"
96
98
  end
97
99
 
98
100
  # Quick rubocop workaround
data/lib/listen/cli.rb CHANGED
@@ -21,7 +21,7 @@ module Listen
21
21
  banner: 'The address to forward filesystem events'
22
22
 
23
23
  class_option :directory,
24
- type: :string,
24
+ type: :array,
25
25
  default: '.',
26
26
  aliases: '-d',
27
27
  banner: 'The directory to listen to'
@@ -1,3 +1,3 @@
1
1
  module Listen
2
- VERSION = '2.9.0'
2
+ VERSION = '2.10.0'
3
3
  end
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: listen
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.9.0
4
+ version: 2.10.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: 2015-03-10 00:00:00.000000000 Z
11
+ date: 2015-03-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: celluloid
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">="
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.15.2
19
+ version: 0.16.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ">="
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.15.2
26
+ version: 0.16.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rb-fsevent
29
29
  requirement: !ruby/object:Gem::Requirement