I want to write an ReSharper extension that performs an action after every build, so I guess I need to first know when a build has completed and the also find out about if the build was successful or not
Any tips about how to do that?
(I'm completely new to making extensions) thanks in advance
You can just use Visual Studio's own events for that. Get an instance of the
DTEobject and subscribe to theOnBuildBeginandOnBuildDoneevents.You can see this in action in the Clippy ReSharper extension. It subscribes to the events, and gets the
DTEinstance from the call toShell.Instance.GetComponent<DTE>().Note that how you reference the
DTEtype is very important - it's a COM reference, and shouldn't be referenced as a Embedded PIA intro type, or ReSharper's component model container will see it as a different type to theDTEinstance it knows about. Instead, simply reference it as a non-PIA type: