有没有Mac OS的程序可以将可执行文件的名称和要监视的文件传递给它,这样每次监视的文件发生更改时就会运行可执行文件?
我想到了类似这样的东西:
$ fwatch /Users/foo/doc.tex /Users/foo/run-pdflatex.sh &
fwatch running. Listening for changes in /Users/foo/doc.tex.
$ echo "This aint no LaTeX" > doc.tex
$ fwatch: Change in /Users/foo/doc.tex detected. Running /Users/foo/run-pdflatex.sh...