You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was trying to add a tag to a docker image, and had to realize I didn't know the right AfterTarget.
Trying to list the targets, using dotnet build simply ignores the -ts and -targets switches and actually builds the project.
The following output was produced:
MSBuild version 17.4.1+9a89d02ff for .NET
Determining projects to restore...
All projects are up-to-date for restore.
ProjectName -> D:\ProjectName\ProjectName\bin\Debug\net6.0\ProjectName.dll
Build succeeded.
0 Warning(s)
0 Error(s)
Time Elapsed 00:00:02.01
Steps to Reproduce
Open VS and create a Blazor Server App (.Net 6, Docker enabled, Linux OS in docker, No Authentication, HTTPS enabled, TLS allowed)
Open Developer Powershell Window in VS, or navigate to the folder in a Powershell window
Type: dotnet build -targets
and hit enter
What exactly do you mean by 'solution in the same directory'?
I am running the command 'dotnet build -targets' inside the folder with the .sln file
(I think that would count as a yes.)
Not inside the folder of the (startup) project file
Issue Description
I was trying to add a tag to a docker image, and had to realize I didn't know the right AfterTarget.
Trying to list the targets, using dotnet build simply ignores the -ts and -targets switches and actually builds the project.
The following output was produced:
MSBuild version 17.4.1+9a89d02ff for .NET
Determining projects to restore...
All projects are up-to-date for restore.
ProjectName -> D:\ProjectName\ProjectName\bin\Debug\net6.0\ProjectName.dll
Build succeeded.
0 Warning(s)
0 Error(s)
Time Elapsed 00:00:02.01
Steps to Reproduce
Open VS and create a Blazor Server App (.Net 6, Docker enabled, Linux OS in docker, No Authentication, HTTPS enabled, TLS allowed)
Open Developer Powershell Window in VS, or navigate to the folder in a Powershell window
Type: dotnet build -targets
and hit enter
Expected Behavior
Output the targets, as described here:
https://learn.microsoft.com/en-us/visualstudio/msbuild/msbuild-targets?view=vs-2022
Actual Behavior
Builds the project
Analysis
No response
Versions & Configurations
PS D:\BlazorApp1> dotnet build version
MSBuild version 17.4.1+9a89d02ff for .NET
MSBUILD : error MSB1009: Project file does not exist.
Switch: version
The text was updated successfully, but these errors were encountered: