MCPcopy Create free account
hub / github.com/cztomczak/cefpython / move_directory

Function move_directory

tools/automate-git.py:230–239  ·  view source on GitHub ↗

Copies a directory from source to target.

(source, target, allow_overwrite=False)

Source from the content-addressed store, hash-verified

228
229
230def move_directory(source, target, allow_overwrite=False):
231 """ Copies a directory from source to target. """
232 if not options.dryrun and os.path.exists(target):
233 if not allow_overwrite:
234 raise Exception("Directory %s already exists" % (target))
235 remove_directory(target)
236 if os.path.exists(source):
237 msg("Moving directory %s to %s" % (source, target))
238 if not options.dryrun:
239 shutil.move(source, target)
240
241
242def is_git_checkout(path):

Callers 1

automate-git.pyFile · 0.85

Calls 2

msgFunction · 0.85
moveMethod · 0.80

Tested by

no test coverage detected