code: def run_apidoc(_):
      modules = os.path.join(RST_SOURCE_DIR, "modules")
      exclude_pattern = os.path.join(PROJECT_ROOT, "contrib*")
      argv = ["-f", "-o", modules, PROJECT_ROOT, exclude_pattern]
  
      from sphinx.ext import apidoc
  
      apidoc.main(argv)
  
      os.remove(os.path.join(modules, "modules.rst"))
  
      from make_config_docs import main
  
      main()
  
file_path: pytext/pytext/docs/source/conf.py
imports: import os
  import sys
  import mock
  from sphinx.domains.python import PythonDomain
label_desc: Use image node_id 1 for calling a global function with example usage: run_apidoc(_) without return types