mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-16 11:48:06 +01:00
[PTRun][Shell]Add a hidden option to use WindowsTerminal (#25661)
* Added an option in ExecutionShell for WindowsTerminal * undo change of nuget.config * Restore nuget.config
This commit is contained in:
@@ -190,6 +190,20 @@ namespace Microsoft.Plugin.Shell
|
||||
|
||||
info = ShellCommand.SetProcessStartInfo("powershell.exe", workingDirectory, arguments, runAsVerbArg);
|
||||
}
|
||||
else if (_settings.Shell == ExecutionShell.WindowsTerminal)
|
||||
{
|
||||
string arguments;
|
||||
if (_settings.LeaveShellOpen)
|
||||
{
|
||||
arguments = $"powershell -NoExit \"{command}\"";
|
||||
}
|
||||
else
|
||||
{
|
||||
arguments = $"powershell \"{command}\"";
|
||||
}
|
||||
|
||||
info = ShellCommand.SetProcessStartInfo("wt.exe", workingDirectory, arguments, runAsVerbArg);
|
||||
}
|
||||
else if (_settings.Shell == ExecutionShell.RunCommand)
|
||||
{
|
||||
// Open explorer if the path is a file or directory
|
||||
|
||||
Reference in New Issue
Block a user