forked from platformio/platformio-core
Merge branch 'develop' of https://github.com/ivankravets/platformio into feature/platform-stm32
This commit is contained in:
@ -37,7 +37,7 @@ def get_home_dir():
|
|||||||
pass
|
pass
|
||||||
|
|
||||||
if not home_dir:
|
if not home_dir:
|
||||||
home_dir = expanduser("~/.platformio")
|
home_dir = join(expanduser("~"), ".platformio")
|
||||||
|
|
||||||
if not isdir(home_dir):
|
if not isdir(home_dir):
|
||||||
makedirs(home_dir)
|
makedirs(home_dir)
|
||||||
@ -85,9 +85,12 @@ def change_filemtime(path, time):
|
|||||||
utime(path, (time, time))
|
utime(path, (time, time))
|
||||||
|
|
||||||
|
|
||||||
def exec_command(args):
|
def exec_command(*args, **kwargs):
|
||||||
use_shell = system() == "Windows"
|
kwargs['stdout'] = PIPE
|
||||||
p = Popen(args, stdout=PIPE, stderr=PIPE, shell=use_shell)
|
kwargs['stderr'] = PIPE
|
||||||
|
kwargs['shell'] = system() == "Windows"
|
||||||
|
|
||||||
|
p = Popen(*args, **kwargs)
|
||||||
out, err = p.communicate()
|
out, err = p.communicate()
|
||||||
return dict(out=out.strip(), err=err.strip())
|
return dict(out=out.strip(), err=err.strip())
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user