0

let's create a normal MSBuild file and name it doSomething.msbuild

<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Target Name="HelloWorld">
    <Message Text="Hello world" />
  </Target>
</Project>

now if you open developer console or old school dotnet folder you can call something like this

C:\temp\msbuild doSomething.msbuild

I get an output like this:

enter image description here

now refering to dotnet core doc

I should be able to do the same

dotnet msbuild doSomething.msbuild

but I'm getting this

enter image description here

as you can see I even tried to pass the target name, but no output is generated. if I ask to see all the preprocess I get this:

enter image description here

even both of the msbuild are using the same build engine version 16.5.0+d4cbfca49 any idea how to fix it? or it's a bug?

1
  • 1
    Try to setup msbuild output verbosity or Importance="High" for message. msbuild and .NET Core cli might use the different verbosity by default. You may look at this question, the idea is the same Apr 29, 2020 at 10:21

1 Answer 1

0

thanks to @PavelAnikhouski

turned out with setting verbosity as normal I can get the same result level as msbuild

dotnet msbuild -verbosity:normal .\doSomething.msbuild

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.