jekyll-watch 1.4.0 → 1.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/jekyll/watcher.rb +14 -2
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1ff18300a98e62ce99a125f340ec16082a22e308
4
- data.tar.gz: 52da74c9961365019cec8e0eb965113387ad8ce9
3
+ metadata.gz: d40afe7b1b23853d3d981f04b6f15f553e9f397f
4
+ data.tar.gz: 0f109a29291aff9c8cca476feeeb0fab8249c0ce
5
5
  SHA512:
6
- metadata.gz: 02908fe91645151699804bbef69a67a6ac75139ecf2dc5dec8e418757e03cdb2768bf8acf2bf9f303aa88b4302f314b6ca30429831c0b550a4ca618814e39a47
7
- data.tar.gz: f5092fefa51179d2cf28502034a5c40e089d69b648aa08976f4eaff5565506db4731ae8b1f4b4b29ccd8eb83710697bc2992860d4510edcbe3816ee44f281fbd
6
+ metadata.gz: de8cab3cc818b39a9e0851ee81a0f0d83e4e4b0aab1f735a15f855ca46ea18ff602140a4373db029f89f5521998f213797469aa5d821a62d52be5cb72c9f0a07
7
+ data.tar.gz: b7d193415b9e643a2935cda00f87d3d2de2af99973d2cff20161c3fb44879ca5c24c2c02672804929bae19387589f5e27ba89fb84afcd25f2a870e0e531ce067
@@ -4,10 +4,22 @@ module Jekyll
4
4
  module Watcher
5
5
  extend self
6
6
 
7
- def watch(options)
7
+ # Public: Continuously watch for file changes and rebuild the site
8
+ # whenever a change is detected.
9
+ #
10
+ # If the optional site argument is populated, that site instance will be
11
+ # reused and the options Hash ignored. Otherwise, a new site instance will
12
+ # be instantiated from the options Hash and used.
13
+ #
14
+ # options - A Hash containing the site configuration
15
+ # site - The current site instance (populated starting with Jekyll 3.2)
16
+ # (optional, default: nil)
17
+ #
18
+ # Returns nothing.
19
+ def watch(options, site = nil)
8
20
  ENV["LISTEN_GEM_DEBUGGING"] ||= "1" if options['verbose']
9
21
 
10
- site = Jekyll::Site.new(options)
22
+ site ||= Jekyll::Site.new(options)
11
23
  listener = build_listener(site, options)
12
24
  listener.start
13
25
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-watch
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Parker Moore
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-04-25 00:00:00.000000000 Z
11
+ date: 2016-07-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: listen