mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-06 03:07:04 +02:00
Merge pull request #453 from Wox-launcher/master
Merge branch 'master' into 'dotnet45'
This commit is contained in:
@@ -143,8 +143,12 @@ namespace Wox.Plugin.CMD
|
||||
|
||||
private void ExecuteCmd(string cmd, bool runAsAdministrator = false)
|
||||
{
|
||||
if (context.API.ShellRun(cmd, runAsAdministrator))
|
||||
var fullCmd = CMDStorage.Instance.LeaveCmdOpen ? $"cmd /k \"{cmd}\" & pause & exit" : cmd;
|
||||
var success = context.API.ShellRun(fullCmd, runAsAdministrator);
|
||||
if (success)
|
||||
{
|
||||
CMDStorage.Instance.AddCmdHistory(cmd);
|
||||
}
|
||||
}
|
||||
|
||||
public void Init(PluginInitContext context)
|
||||
|
||||
Reference in New Issue
Block a user