diff --git a/shell/AIShell.Integration/Commands/StartAishCommand.cs b/shell/AIShell.Integration/Commands/StartAishCommand.cs index ba3c226d..3501c4e9 100644 --- a/shell/AIShell.Integration/Commands/StartAishCommand.cs +++ b/shell/AIShell.Integration/Commands/StartAishCommand.cs @@ -16,8 +16,8 @@ protected override void BeginProcessing() { if (Path is null) { - Path = "aish"; - if (SessionState.InvokeCommand.GetCommand(Path, CommandTypes.Application) is null) + var app = SessionState.InvokeCommand.GetCommand("aish", CommandTypes.Application); + if (app is null) { ThrowTerminatingError(new( new NotSupportedException("The executable 'aish' cannot be found."), @@ -25,6 +25,8 @@ protected override void BeginProcessing() ErrorCategory.NotInstalled, targetObject: null)); } + + Path = app.Source; } else {