Permalink
Browse files

work on windows.

  • Loading branch information...
1 parent aba59d7 commit 19d7e8a2fe65f43d1404cdd46fcf20609e74ecdd @mattn committed Sep 1, 2011
Showing with 4 additions and 0 deletions.
  1. +4 −0 autoload/bg.vim
View
@@ -32,6 +32,9 @@ fun! bg#Run(cmd, outToTmpFile, onFinish)
let cmd = '{ '.bg#ListToCmd(a:cmd).'; }'
if a:outToTmpFile
let tmpFile = tempname()
+ if has('win32') || has('win64')
+ let tmpFile = substitute(tmpFile, '\\', '/', 'g')
+ endif
let cmd .= ' &> '.shellescape(tmpFile)
let escapedFile = ','.S([string(tmpFile)])[0]
else
@@ -103,6 +106,7 @@ py << EOF
import threading
import string
import sys, tokenize, cStringIO, types, socket, string, vim, os
+import subprocess
from subprocess import Popen, PIPE, STDOUT
class MyThread ( threading.Thread ):

0 comments on commit 19d7e8a

Please sign in to comment.