msbuild

How to add extra files to the package that is generated by msbuild called by an Azure Resource Group Project in Visual Studio

无人久伴 提交于 2021-02-10 06:46:44
问题 So I have a solution made up of a web project and an Azure Resource Group project much like what is described here: https://blogs.technet.microsoft.com/georgewallace/2015/05/10/deploying-a-website-with-content-through-visual-studio-with-resource-groups/ The issue I am having is that the web project needs to include some EXTRA files in its bin directory in order to function. Now through the normal package process on the web project itself I accomplish this by adding a custom target and hook

How to add extra files to the package that is generated by msbuild called by an Azure Resource Group Project in Visual Studio

帅比萌擦擦* 提交于 2021-02-10 06:46:04
问题 So I have a solution made up of a web project and an Azure Resource Group project much like what is described here: https://blogs.technet.microsoft.com/georgewallace/2015/05/10/deploying-a-website-with-content-through-visual-studio-with-resource-groups/ The issue I am having is that the web project needs to include some EXTRA files in its bin directory in order to function. Now through the normal package process on the web project itself I accomplish this by adding a custom target and hook

.NETStandard multi-targeting library packages do not get restored when building

こ雲淡風輕ζ 提交于 2021-02-10 05:44:15
问题 Background: I have created a multi-targeting library that targets net40 , net462 , and netstandard2.0 . The purpose of this library is to wrap StackExchange.Redis and some related reconnect logic. For net40 I need to use an older version of the package than the newer targets. Here is my csproj file: <Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <TargetFrameworks>net40;net462;netstandard2.0</TargetFrameworks> </PropertyGroup> <ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">

Build project targeting for both x86 and x64 platform

心已入冬 提交于 2021-02-10 05:42:27
问题 In my solution, there is a class library which is an excel add-in. When I build the solution or that project, I want this project will be built firstly targeting for x86 with outputing a file named xxx.dll , and then targeting for x64 with outputing a file named xxx_x64.dll . How should I do for this, or how could I edit the csproj file? Thanks. 回答1: How should I do for this, or how could I edit the csproj file? The name of assembly xxx.dll is defined by the property AssemblyName in the

Cannot compile template C++/CLI (.NET Core 3.1) project via dotnet build command

若如初见. 提交于 2021-02-10 05:37:15
问题 Install latest stable Visual Studio 2019 16.4.2 (check .NET Core Development and Desktop development with C++ workloads, also make sure that C++/CLI support component in checked). Create new project with CLR Class Library (.NET Core) template (or CLR Empty Project (.NET Core) if you like). Compilation via dotnet build command will fail ( dotnet build CLRNetCoreTest.sln /p:Configuration=Debug /p:Platform=x86 ): Compilation via msbuild command is successfull ( "%ProgramFiles(x86)%\Microsoft

SonarQube analysis with MSBuild: Line is out of range in file

风格不统一 提交于 2021-02-10 04:54:18
问题 So, we have a TeamCity project building a C# webapi project using .NET 4.5 which includes a SonarQube analysis. At the end of the analysis, we receive the following exception: [13:41:13][Step 14/16] ERROR: Error during SonarQube Scanner execution [13:41:13][Step 14/16] java.lang.IllegalStateException: Line 65 is out of range in the file App_Start/UnityConfig.cs (lines: 64) What did I already check: UPDATE: Further analysis proves that the error is caused due to dotCover code coverage analysis

Visual Studio 2019 - error MSB8020: The build tools for Visual Studio 2013 cannot be found

心不动则不痛 提交于 2021-02-10 03:12:56
问题 This is the GitHub page where I'm trying to use msbuild.exe only it's throwing this following error: 1>------ Build started: Project: keycastow, Configuration: Debug|Win32 ------ C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppBuild.targets(379,5): error MSB8020: The build tools for Visual Studio 2013 (Platform Toolset = 'v120') cannot be found. To build using the v120 build tools, please install Visual Studio 2013 build tools.

How to prevent resource assembly generation for embedded resources

|▌冷眼眸甩不掉的悲伤 提交于 2021-02-09 11:45:55
问题 I have a project which embeds some files into it, two of which ends with .SMS.something . When the project is compiled, a satellite assembly for the "SMS" culture is generated even though I have not specified anywhere that I want to use satellite assemblies, and is it even a culture? I have searched all over the place for an explanation, but I am at a loss. The only things I found were people trying to embed their resource assemblies for actual cultures into their executable, but this is not

Is It possible to build asp.net core project using MSBuild from code?

不想你离开。 提交于 2021-02-09 10:42:30
问题 I want to build asp.net core project using another C# project. Here is the sample code. ( I am using Visual Studio 2015) var projectCollection = new Microsoft.Build.Evaluation.ProjectCollection(Microsoft.Build.Evaluation.ToolsetDefinitionLocations.Registry); projectCollection.DefaultToolsVersion = "14.0"; projectCollection.RegisterLogger(new Microsoft.Build.Logging.ConsoleLogger(Microsoft.Build.Framework.LoggerVerbosity.Detailed)); var project = projectCollection.LoadProject(@"H:\Development

Is It possible to build asp.net core project using MSBuild from code?

て烟熏妆下的殇ゞ 提交于 2021-02-09 10:39:37
问题 I want to build asp.net core project using another C# project. Here is the sample code. ( I am using Visual Studio 2015) var projectCollection = new Microsoft.Build.Evaluation.ProjectCollection(Microsoft.Build.Evaluation.ToolsetDefinitionLocations.Registry); projectCollection.DefaultToolsVersion = "14.0"; projectCollection.RegisterLogger(new Microsoft.Build.Logging.ConsoleLogger(Microsoft.Build.Framework.LoggerVerbosity.Detailed)); var project = projectCollection.LoadProject(@"H:\Development