Skip to content
This repository was archived by the owner on Oct 13, 2025. It is now read-only.

Commit 77d04d2

Browse files
committed
Actually use guard for something useful and restart Unicorn when files change.
1 parent 3602ec5 commit 77d04d2

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Guardfile

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,10 @@
1010
# * :daemonize (default is true) - should the Unicorn server start daemonized?
1111
# * :config_file (default is "config/unicorn.rb") - the path to the unicorn file
1212
# * :pid_file (default is "tmp/pids/unicorn.pid") - the path to the unicorn pid file
13-
guard :unicorn, :daemonize => false, :port => 4567
13+
guard :unicorn, :daemonize => false, :port => 4567 do
14+
watch('app.rb')
15+
watch(%|api/.*\.rb|)
16+
watch(%|lib/.*\.rb|)
17+
watch(%|models/.*\.rb|)
18+
watch(%|config/.*\.rb|)
19+
end

0 commit comments

Comments
 (0)