MCPcopy Index your code
hub / github.com/nodejs/node / Execute

Function Execute

deps/v8/tools/android-run.py:52–70  ·  view source on GitHub ↗
(cmdline)

Source from the content-addressed store, hash-verified

50 return 1 if failed else 0
51
52def Execute(cmdline):
53 (fd_out, outname) = tempfile.mkstemp()
54 (fd_err, errname) = tempfile.mkstemp()
55 process = subprocess.Popen(
56 args=cmdline,
57 shell=True,
58 stdout=fd_out,
59 stderr=fd_err,
60 )
61 exit_code = process.wait()
62 os.close(fd_out)
63 os.close(fd_err)
64 output = open(outname).read()
65 errors = open(errname).read()
66 os.unlink(outname)
67 os.unlink(errname)
68 sys.stdout.write(output)
69 sys.stderr.write(errors)
70 return exit_code or Check(output, errors)
71
72def Escape(arg):
73 def ShouldEscape():

Callers 1

MainFunction · 0.70

Calls 7

CheckFunction · 0.70
closeMethod · 0.65
openFunction · 0.50
waitMethod · 0.45
readMethod · 0.45
unlinkMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…