As from any program, you can detect that using a FileSystemWatcher. This won't indicate if the file changed in Visual Studio or somewhere else, but it will give you a notification whenever the file changes on disk. Also, depending on what your plug-in is, it may be that it should not be a plugin at all but rather a "custom tool". If so, VS will re-run the tool whenever a file associated with the tool is saved. Look for example at the Coco/R for Visual Studio article here on CP.