Open JaynieBai opened 1 month ago
@JaynieBai could you please check whether it is shell or msbuild parsing causing this error? For that, please check which parameters msbuild received. You can set $env:MSBUILDDEBUGONSTART=1
, run the build, start debugging and look the parameters that msbuild received in the code.
Issue Description
Test escape ',' and "," and %3C in the powershell , cmd, bash and zsh. Found "," and ',' is not supported in the following 4 shells and cmd error is different from others.
Test ";=" and ';=' and %3B in 4 shells. Found when ";=" and ';=' global property, it reports error in 4 shells with the same error MSB1006: Property is not valid. But = and ; work well separately for global property
Powershell
With quotes: MSBUILD : error MSB1005: Specify a property and its value.
With double quotes: MSBUILD : error MSB1005: Specify a property and its value.
Html Codes. Works well
CMD
With quotes: MSBUILD : error MSB1006: Property is not valid.
With double quotes: MSBUILD : error MSB1005: Specify a property and its value.
With html codes: Good![image](https://github.com/dotnet/msbuild/assets/26814373/6db712b4-d914-4c60-9cb7-779e263059e4)
bash
With quotes: MSBUILD : error MSB1005: Specify a property and its value.
With double quotes: MSBUILD : error MSB1005: Specify a property and its value.
Html codes: works well
ZSH
With quotes: MSBUILD : error MSB1005: Specify a property and its value.
With double quotes: MSBUILD : error MSB1005: Specify a property and its value.
Html codes work well![image](https://github.com/dotnet/msbuild/assets/26814373/da5da97e-562c-4420-81f2-bbdd4db98add)
Steps to Reproduce
custom-proj1.zip dotnet version 9.0.100-preview.3.24204.13
Expected Behavior
dotnet build should support such properties "," and ";=" as msbuild.exe
Actual Behavior
Dotnet build doesn't support the global property ", " and ";="
Analysis
No response
Versions & Configurations
No response