Here’s a quick little Vim plugin for document refreshing. When I’m making changes to ADHOC, I like to see how they affect the generated code. Usually I have it generating to the same file repeatedly (“test.c”, for example). In that case, I could just run
tail -f test.c, but then I wouldn’t get Vim’s helpful syntax highlighting. This plugin essentially makes Vim behave like
tail -f. It sleeps for the specified duration (5 seconds by default), checks whether the file has been modified, refreshes it, if it has, and then calls itself again. Also, in my humble opinion, this plugin has the best name of all time.