-
Notifications
You must be signed in to change notification settings - Fork 32
Jed Northridge edited this page Jan 18, 2014
·
10 revisions
Is it possible to automatically run the reveal-ck generate
command each time I change my slides file?
You can use guard and the guard-shell to accomplish this.
Start with a gem install guard-shell
, and then create a Guardfile
that contains this content:
guard :shell do
watch(/^slides\.\S{2,7}$/) do |m|
puts "Matched with '#{m}'"
`reveal-ck generate`
end
watch(/^config\.yml$/) do |m|
puts "Matched with '#{m}'"
`reveal-ck generate`
end
end
Then run guard
in your project. Any changes to a file beginning with "slides" (slides.md
, slides.haml
, etc) or the central configuration will cause a generate command to run.
You'll then be able to just refresh your browser and see the new content.
...
...
...
...