docs: def gendocs():
      "create some doc pages automatically"
      helppage = path("docs/references-cli-usage.rst")
      content = [
          ".. automatically generated using 'paver gendocs'.",
          "",
          ".. contents::",
          "    :local:",
          "",
          ".. note::",
          "",
          "    The help output presented here applies to version ``%s`` of the tools."
              % sh("pyroadmin --version", capture=True).split()[1],
          "",
      ]
  
      for tool in sorted(project.entry_points["console_scripts"]):
          tool, _ = tool.split(None, 1)
          content.extend([
              ".. _cli-usage-%s:" % tool,
              "",
              tool,
              '^' * len(tool),
              "",
              "::",
              "",
          ])
          help_opt = "--help-fields --config-dir /tmp" if tool == "rtcontrol" else "--help"
          help_txt = sh("%s -q %s" % (tool, help_opt), capture=True, ignore_error=True).splitlines()
          content.extend('    ' + i for i in help_txt
                         if ' on Python ' not in i and 'Copyright (c) 200' not in i
                         and 'see the full documentation' not in i
                         and '    https://pyrocore.readthedocs.io/' not in i)
          content.extend([
              "",
          ])
  
      content = [line.rstrip() for line in content if all(
          i not in line for i in (", Copyright (c) ", "Total time: ", "Configuration file '/tmp/")
      )]
      content = [line for line, succ in zip(content, content[1:] + ['']) if line or succ] # filter twin empty lines
      helppage.write_lines(content)