Skip to content

Commit

Permalink
chore(watchr): watchr scripts should output logs to terminal
Browse files Browse the repository at this point in the history
Having the extra level of indirection by using logs/*.log file
only makes it more difficult to use these scripts. After this
change it will be enough to just start the watchr and watch the
terminal it was started in.
  • Loading branch information
IgorMinar committed Oct 31, 2011
1 parent ef875ad commit 95fdb12
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions watchr-docs.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
# config file for watchr http://github.com/mynyml/watchr
# install: gem install watchr
# run: watch watchr.rb
# note: make sure that you have jstd server running (server.sh) and a browser captured
# run: watch watchr-docs.rb

watch( '^src/|^docs/' ) do
%x{ echo "\n\ndoc run started @ `date`" > logs/docs.log; node docs/src/gen-docs.js &> logs/docs.log & }
system 'echo "\n\ndoc run started @ `date`"; node docs/src/gen-docs.js'
end
3 changes: 1 addition & 2 deletions watchr.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,5 @@
# note: make sure that you have jstd server running (server.sh) and a browser captured

watch( '(src|test|example)/' ) do
%x{ echo "\n\ntest run started @ `date`" > logs/jstd.log; ./test.sh &> logs/jstd.log & }
%x{ echo "\n\nlint started @ `date`" > logs/lint.log; rake lint &> logs/lint.log & }
system 'echo "\n\ntest run started @ `date`"; ./test.sh '
end

0 comments on commit 95fdb12

Please sign in to comment.