Skip to content

Commit

Permalink
open click-to-open editor in foreground for windows (#14307)
Browse files Browse the repository at this point in the history
spent a lot of hours trying to figure out why did the editor window not open in the foreground on windows.

The fix was super simple  : /
Needed to add `detached: true` option in child_process.spawn call

Fixes: #14016
  • Loading branch information
darshkpatel authored Jun 22, 2020
1 parent eead55c commit 19f3306
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,7 @@ function launchEditor(fileName: string, lineNumber: number, colNumber: number) {
// launch .exe files.
p = child_process.spawn('cmd.exe', ['/C', editor].concat(args), {
stdio: 'inherit',
detached: true,
})
} else if (isTerminalEditor(editor)) {
if (process.platform === 'darwin') {
Expand Down

0 comments on commit 19f3306

Please sign in to comment.