After Publish event in Visual Studio

UPDATE: seems like in VS 2019 and .NET 5 you can now use Publish target. <Target Name=”Test” AfterTargets=”Publish”> <Exec Command=”blablabla” /> </Target> Here’s my old answer that also works: MS has confirmed, that when publishing to file system they don’t have any target to launch after that. “We currently do not support executing custom targets … Read more

How do I enable Visual Studio 2010 to break when a first chance exception happens?

You may want to check the Debug menu in Visual Studio 2010. In there you will find the Exception submenu, in where you can select which type of exception you want Visual Studio to stop. Setting the debugger to break when an exception is thrown The debugger can break execution at the point where an exception is … Read more

Mercurial .hgignore for Visual Studio 2010 projects

The new things are related to MSTest stuff. This is the one that I use: # use glob syntax syntax: glob *.obj *.pdb *.user *.aps *.pch *.vspscc *.vssscc *_i.c *_p.c *.ncb *.suo *.tlb *.tlh *.bak *.[Cc]ache *.ilk *.log *.lib *.sbr *.scc *.DotSettings [Bb]in [Dd]ebug*/** obj/ [Rr]elease*/** _ReSharper*/** NDependOut/** packages/** [Tt]humbs.db [Tt]est[Rr]esult* [Bb]uild[Ll]og.* *.[Pp]ublish.xml *.resharper *.ncrunch* … Read more

Visual Studio Disabling Missing XML Comment Warning

As suggested above, in general I don’t think that these warnings should be ignored (suppressed). To summarise, the ways around the warning would be to: Suppress the warning by changing the project Properties > Build > Errors and warnings > Suppress warnings by entering 1591 Add the XML documentation tags (GhostDoc can be quite handy … Read more

How to set CUDA compiler flags in Visual Studio 2010?

You can select the options for the GPU Code Generation in this dialog: In this case “compute_20” means that i am compiling for the virtual compute architecture 2.0 – virtual architecture influences the PTX generation stage. The second part that comes after the coma is “sm_21”.This influences the CUBIN generation stage. It defines the real … Read more

How do I configure MSBuild to use a saved publishProfile for WebDeploy?

I’m sorry to tell you that the publish.xml file which VS2010 uses was not designed to be used in this way. In fact it was not even designed to be checked-in/shared with others. The logic for reading/writing those files are strictly contained inside Visual Studio and not available through MSBuild. So there is no straight … Read more

tech