code: def copy_tree_contents(srcdir: str, destdir: str,
                         destroy: bool = False) -> None:
      
      log.info("Copying directory {} -> {}", srcdir, destdir)
      if os.path.exists(destdir):
          if not destroy:
              raise ValueError("Destination exists!")
          if not os.path.isdir(destdir):
              raise ValueError("Destination exists but isn't a directory!")
          log.debug("... removing old contents")
          rmtree(destdir)
          log.debug("... now copying")
      shutil.copytree(srcdir, destdir)
docs: Recursive copy. Unlike :func:`copy_tree_root`, :func:`copy_tree_contents`
      works as follows. With the file structure:
  
      .. code-block:: none
  
          /source/thing/a.txt
          /source/thing/b.txt
          /source/thing/somedir/c.txt
  
      the command
  
      .. code-block:: python
  
          copy_tree_contents("/source/thing", "/dest")
  
      ends up creating:
  
      .. code-block:: none
  
          /dest/a.txt
          /dest/b.txt
          /dest/somedir/c.txt