MCPcopy Index your code
hub / github.com/ekalinin/nodeenv / node_version_from_args

Function node_version_from_args

nodeenv.py:185–194  ·  view source on GitHub ↗

Parse the node version from the argparse args

(args)

Source from the content-addressed store, hash-verified

183
184
185def node_version_from_args(args):
186 """
187 Parse the node version from the argparse args
188 """
189 if args.node == 'system':
190 out, err = subprocess.Popen(
191 ["node", "--version"], stdout=subprocess.PIPE).communicate()
192 return parse_version(clear_output(out))
193
194 return parse_version(args.node)
195
196
197def create_logger():

Callers 1

create_environmentFunction · 0.85

Calls 2

parse_versionFunction · 0.85
clear_outputFunction · 0.85

Tested by

no test coverage detected