I would like to open an external editor to edit string content (that would be written to temporary files).
What I need is a command to open the editor with a filename and get a notification whenever the file has been saved. The solution to this problem has to be platform specific. Starting with Mac OS, here are the three solutions that could work (preferred solutions first):
- kqueue with EVFILT_VNODE / NOTE_WRITE (BSD C interface)
- ODB Editor Suite (AppleEvents, compatible with BBEdit, TextMate, etc)
- file stat polling with a Timer (arrgggh)
Any advice ?