MCPcopy Create free account
hub / github.com/numpy/numpy / command_by_line

Function command_by_line

numpy/distutils/cpuinfo.py:46–52  ·  view source on GitHub ↗
(cmd, successful_status=(0,), stacklevel=1)

Source from the content-addressed store, hash-verified

44 return info
45
46def command_by_line(cmd, successful_status=(0,), stacklevel=1):
47 ok, output = getoutput(cmd, successful_status=successful_status,
48 stacklevel=stacklevel+1)
49 if not ok:
50 return
51 for line in output.splitlines():
52 yield line.strip()
53
54def key_value_from_command(cmd, sep, successful_status=(0,),
55 stacklevel=1):

Callers 2

key_value_from_commandFunction · 0.85
__init__Method · 0.85

Calls 3

getoutputFunction · 0.85
splitlinesMethod · 0.80
stripMethod · 0.80

Tested by

no test coverage detected