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

Function try_copy

tools/install.py:67–73  ·  view source on GitHub ↗
(options, path, dest)

Source from the content-addressed store, hash-verified

65 return source_path, target_path
66
67def try_copy(options, path, dest):
68 source_path, target_path = mkpaths(options, path, dest)
69 if not options.silent:
70 print('installing %s' % target_path)
71 try_mkdir_r(os.path.dirname(target_path))
72 try_unlink(target_path) # prevent ETXTBSY errors
73 return shutil.copy2(source_path, target_path)
74
75def try_remove(options, path, dest):
76 _source_path, target_path = mkpaths(options, path, dest)

Callers 1

installFunction · 0.85

Calls 4

mkpathsFunction · 0.85
try_mkdir_rFunction · 0.85
try_unlinkFunction · 0.85
printFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…