0xabu / MsBuildCompileCommandsJson

An MSBuild logger that emits compile_commands.json for C++ projects
MIT License
44 stars 8 forks source link

cctmp.json: The term 'cctmp.json' is not recognized as a name of a cmdlet #3

Closed roachsinai closed 2 years ago

roachsinai commented 2 years ago

I read from Readme, support use ;cctmp.json follow -logger:F:\code\tools\MsBuildCompileCommandsJson\bin\Release\netstandard2.0\CompileCommandsJson.dll;cctmp.json to change export json file name, but I got below error:

cctmp.json: The term 'cctmp.json' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

So, could you please tell me what's wrong with my command?

& "${env:ProgramFiles(x86)}\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\MSBuild.exe" -logger:F:\code\tools\MsBuildCompileCommandsJson\bin\Release\netstandard2.0\CompileCommandsJson.dll;cctmp.json ./YBlaze.sln /t:Rebuild

0xabu commented 2 years ago

You'll need to escape the ; character for PowerShell so it is passed to msbuild and not interpreted as a command separator.

roachsinai commented 2 years ago

Got it, thanks!