The simplest approach I found is to use two terminal windows: one for jekyll serve --watch and one for guard .
I tried the guard-jekyll-plus approach proposed by Nobu , but I had a lot of errors.
As Shumushin pointed out , Jekyll can handle the automatic rebuilding process, you just start it with jekyll serve --watch
Now, to start the LiveReload operating mode with the guard-livereload function in the second terminal window. This is basically the same as Jan Segre's answer , but without guard-jekyll .
My Guardfile as follows:
guard 'livereload' do watch(/^_site/) end
And my Gemfile :
gem 'jekyll' gem 'guard' gem 'guard-livereload'
Note You still need to enable the script download function on the index.html page; this is the βglueβ that ties guard-livereload and the browser together.
<script src="http://localhost:35729/livereload.js"></script>
aboy021 Apr 02 '15 at 8:19
source share