Skip to content
This repository was archived by the owner on Mar 12, 2020. It is now read-only.

Commit c01d3bf

Browse files
committed
Fixed #5 for windows
1 parent bf5ee96 commit c01d3bf

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

SQLToolsModels.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,11 @@ def run(self):
245245
self.tmp.close()
246246

247247
self.args = map(str, self.args)
248-
self.process = subprocess.Popen(self.args, stdout=subprocess.PIPE,stderr=subprocess.PIPE, stdin=open(self.tmp.name), env=os.environ.copy())
248+
si = None
249+
if os.name == 'nt':
250+
si = subprocess.STARTUPINFO()
251+
si.dwFlags |= subprocess.STARTF_USESHOWWINDOW
252+
self.process = subprocess.Popen(self.args, stdout=subprocess.PIPE,stderr=subprocess.PIPE, stdin=open(self.tmp.name), env=os.environ.copy(), startupinfo=si)
249253

250254
results, errors = self.process.communicate()
251255

0 commit comments

Comments
 (0)