Adding file watcher instead for infinite loop