I'm trying to debug the MSBuild Customtask, that I have just created, but for some reason it never stops at the breakpoint. I've even tried this:
public override bool Execute()
{
System.Diagnostics.Debugger.Break();
And added a break point on that line... I even eliminated all the other code in the method and that didn't change anything.
Is there anything special required to be able to debug the creation of custom tasks for MSBuild ?
It's a bit of a hack, but you could always just put this line of code wherever it is that you want to start debugging:
System.Diagnostics.Debugger.Launch();
When you invoke it, the CLR will launch a dialog asking you what debugger you want to attach.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With