MCPcopy Create free account
hub / github.com/boostorg/build / set_tree

Method set_tree

v2/test/BoostBuild.py:324–339  ·  view source on GitHub ↗
(self, tree_location)

Source from the content-addressed store, hash-verified

322 # Methods that change the working directory's content.
323 #
324 def set_tree(self, tree_location):
325 # It is not possible to remove the current directory.
326 d = os.getcwd()
327 os.chdir(os.path.dirname(self.workdir))
328 shutil.rmtree(self.workdir, ignore_errors=False)
329
330 if not os.path.isabs(tree_location):
331 tree_location = os.path.join(self.original_workdir, tree_location)
332 shutil.copytree(tree_location, self.workdir)
333
334 os.chdir(d)
335 def make_writable(unused, dir, entries):
336 for e in entries:
337 name = os.path.join(dir, e)
338 os.chmod(name, os.stat(name).st_mode | 0222)
339 os.path.walk(".", make_writable, None)
340
341 def write(self, file, content, wait=True):
342 nfile = self.native_file_name(file)

Callers 13

railsys.pyFile · 0.80
startup_v2.pyFile · 0.80
prebuilt.pyFile · 0.80
project_test3.pyFile · 0.80
project_test4.pyFile · 0.80
example_qt4.pyFile · 0.80
example_gettext.pyFile · 0.80
core_language.pyFile · 0.80
example_make.pyFile · 0.80
test2.pyFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected