Skip to content

Commit

Permalink
Fix VS profile command generation (#15439)
Browse files Browse the repository at this point in the history
This regressed in f06cd17. It seems like the change went untested,
because it appends an extra " after -startdir=none.
This changeset also avoids calling `append()` twice.

Closes #15436

## Validation Steps Performed
* VS Developer Command Prompt works ✅
  • Loading branch information
lhecker authored May 25, 2023
1 parent 245b13b commit 0073e36
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/cascadia/TerminalSettingsModel/VsDevCmdGenerator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,12 @@ std::wstring VsDevCmdGenerator::GetProfileCommandLine(const VsSetupConfiguration
commandLine.append(GetDevCmdScriptPath(instance));
// The "-startdir" parameter will prevent "vsdevcmd" from automatically
// setting the shell path so the path in the profile will be used instead.
commandLine.append(LR"(" -startdir=none)");
#if defined(_M_ARM64)
commandLine.append(LR"(" -arch=arm64 -host_arch=x64)");
commandLine.append(LR"(" -startdir=none -arch=arm64 -host_arch=x64)");
#elif defined(_M_AMD64)
commandLine.append(LR"(" -arch=x64 -host_arch=x64)");
commandLine.append(LR"(" -startdir=none -arch=x64 -host_arch=x64)");
#else
commandLine.append(LR"(" -startdir=none)");
#endif
return commandLine;
}
Expand Down

0 comments on commit 0073e36

Please sign in to comment.