code: def install(path, v=False, u=False):
      """Installs a theme"""
      if not os.path.exists(path):
          err(path + " : no such file or directory")
      elif not os.path.isdir(path):
          err(path + " : not a directory")
      else:
          theme_name = os.path.basename(os.path.normpath(path))
          theme_path = os.path.join(_THEMES_PATH, theme_name)
          exists = os.path.exists(theme_path)
          if exists and not u:
              err(path + " : already exists")
          elif exists:
              remove(theme_name, v)
              install(path, v)
          else:
              if v:
                  print(f"Copying '{path}' to '{theme_path}' ...")
              try:
                  shutil.copytree(path, theme_path)
  
                  try:
                      if os.name == "posix":
                          for root, dirs, files in os.walk(theme_path):
                              for d in dirs:
                                  dname = os.path.join(root, d)
                                  os.chmod(dname, 493)  # 0o755
                              for f in files:
                                  fname = os.path.join(root, f)
                                  os.chmod(fname, 420)  # 0o644
                  except OSError as e:
                      err(
                          "Cannot change permissions of files "
                          "or directory in `{r}':\n{e}".format(
                              r=theme_path, e=str(e)
                          ),
                          die=False,
                      )
              except Exception as e:
                  err(
                      "Cannot copy `{p}' to `{t}':\n{e}".format(
                          p=path, t=theme_path, e=str(e)
                      )
                  )
  
file_path: pelican/pelican/tools/pelican_themes.py
imports: import argparse
  import os
  import shutil
  import sys
label_desc: Use image node_id 6 for calling a global function with example usage: install(path, v, u) without return types