watch file or directory change accurately