tagged [msbuild]

Execute Unit Tests using MsBuild command line

Execute Unit Tests using MsBuild command line I use scripting for this: And I build solution .sln Now, I would like execute all Unit Tests and check all is OK. How can I execute unit tests of .csproj ...

What does BootstrapperPackage mean inside the *.csproj project

What does BootstrapperPackage mean inside the *.csproj project I am upgrading lots of C# projects from vs.net 2008 to vs.net 2010 rc. I notice that the upgrade creates a BootstrapperPackage section in...

14 Feb at 20:35

How can I get the current directory in an MSBuild script?

How can I get the current directory in an MSBuild script? In my MSBuild script I need to pass the full directory as a parameter. How can I get it? Example: I am running the script from , and I want a ...

3 Jun at 00:0

Include pdb files into my nuget (nupkg) files

Include pdb files into my nuget (nupkg) files I am using MSBuild to generate my nuget packages. Is there any command I need to set, to allow it to include my `.pdb` files, for stepping into the source...

18 Jan at 07:35

Visual Studio 2017 package tab is missing in project settings

Visual Studio 2017 package tab is missing in project settings I created a simple library .NET Framework project. I would like to generate NuGet packages after build as described [here](https://blog.nu...

12 Jun at 16:53

NuGet behind a proxy

NuGet behind a proxy I figure out that NuGet allows proxy settings configuration since [1.4 version (June 2011)](https://learn.microsoft.com/en-us/nuget/release-notes/nuget-1.4). But, I can't find any...

4 Oct at 09:31

How do you get the current project directory from C# code when creating a custom MSBuild task?

How do you get the current project directory from C# code when creating a custom MSBuild task? Instead of running an external program with its path hardcoded, I would like to get the current Project D...

3 May at 08:14

How do we authenticate against a secured NuGet server with Cake build?

How do we authenticate against a secured NuGet server with Cake build? We are working on automating our builds using Cake Build and we use NuGet packages from nuget.org but we also have our own NuGet ...

Why is <Target Name="Build"> not found in any .csproj file?

Why is not found in any .csproj file? Just curious - whenever I see xml of .csproj , it starts with `DefaultTargets="Build"` and hence I assume that `` should be present; However, I have never found t...

9 Nov at 21:43

Could not load file or assembly System.Numeric.Vectors in ML.NET

Could not load file or assembly System.Numeric.Vectors in ML.NET I created a new console application .net46, install the latest ML and tried a simple LDA. Got the error above. None of the fix that I f...

15 Dec at 08:50

What does Microsoft.Common.props do

What does Microsoft.Common.props do I noticed that when I create a project using Class Library template the .csproj contains import of Microsoft.Common.props However when I create a project using Unit...

27 Apr at 20:5

Is there a Visual Studio Build Profiler?

Is there a Visual Studio Build Profiler? My VS.NET 2008 solution is taking longer and longer to compile (ASP.NET 3.5 + ASP.NET MVC 2 + C#) and I am wondering if there is a way to know what project tak...

12 Aug at 05:54

Using Microsoft.Build.Evaluation to publish a database project (.sqlproj)

Using Microsoft.Build.Evaluation to publish a database project (.sqlproj) I need to be able to publish an SSDT project programmatically. I am looking at using Microsoft.Build to do so but can not find...

How do you create portable databases with MsBuild?

How do you create portable databases with MsBuild? I want to store in my solution a project containing the database creation scripts. When this project is built, it must generate a database file, whic...

MSBuild is not generating publish web page (ClickOnce)

MSBuild is not generating publish web page (ClickOnce) I am facing a problem that when I publish my ClickOnce application through MSBuild (4.0), the (or default.htm) isn't created in the app.publish f...

25 Sep at 20:26

Can I set LARGEADDRESSAWARE from within Visual Studio?

Can I set LARGEADDRESSAWARE from within Visual Studio? I have a .NET assembly that needs to be 32-Bit and needs to be `/LARGEADDRESSAWARE`. I know how to do this with `EditBin`, but I wonder if there ...

Build Failed. See the build log for detail

Build Failed. See the build log for detail I create a new project, click compile, and get this error: > Build Failed. See the build log for details. In the build log there is only this: Here is what I...

Can "legacy" .NET projects also use the new NuGet 3 features?

Can "legacy" .NET projects also use the new NuGet 3 features? The new NuGet version fixes lots of problems (e.g. transitive dependency capabilities, dependency resolution at build time, single package...

14 Aug at 13:10

Installing a windows service on remote machine using given username

Installing a windows service on remote machine using given username What is the best way to install a windows service written in C# (in the standard way) on a remote machine, where I need to provide t...

21 Jul at 12:54

Define a preprocessor value from command line using MSBuild

Define a preprocessor value from command line using MSBuild I need to create a demo version of an existing large application consisting of multiple projects. I'd like to use the existing projects, and...

The requested operation cannot be performed error when compiling an XNA project

The requested operation cannot be performed error when compiling an XNA project When compiling a project for the second time I get the following error message. I have to close down VS 2010 and it comp...

App.config replacements for unit tests

App.config replacements for unit tests my continuous integration server (TeamCity) is configured to run all the unit tests in our app on build. Prior to running those tests, i need to change some of t...

Override target framework from command line

Override target framework from command line I want to build a `c#` project(.csproj) from commandline using `msbuild` and want to target .Net2.0 runtime. I see that the project xml file has `2 tags` of...

17 Aug at 09:54

How to build .csproj with C# 7 code from command line (msbuild)

How to build .csproj with C# 7 code from command line (msbuild) I use some C# 7 features in my project: and it builds fine in visual studio 2017, but I get an error on my CI agent when using old msbui...

6 Sep at 08:44

How do I build a solution programmatically in C#?

How do I build a solution programmatically in C#? How do I build a C# solution programmatically? I should be able to pass the path of a solution and get the output messages (or just build the solution...

3 Jan at 12:38