Skip to content

Commit b825030

Browse files
committed
Change generate_exclude script to watch templates for changes
1 parent 8cf0f4c commit b825030

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

generate_exclude.rb

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
def start_watch(paths)
44
require 'listen'
55
system "Jekyll build"
6-
6+
77
listener = Listen.to(paths) do |modified, added, removed|
88
puts "\n Modified File: #{modified} \n\n Building Jekyll site."
99
File.delete("SlugLog.log") if File.exist?("SlugLog.log")
@@ -45,5 +45,6 @@ def start_watch(paths)
4545
else
4646
new_config = orig_config.gsub(/exclude: \[[^\]]*\]/, "exclude: " + exclude_text)
4747
File.write(config_file, new_config)
48+
paths_to_include.push("_templates/")
4849
start_watch(paths_to_include)
4950
end

0 commit comments

Comments
 (0)