How to use the pdoc.__version__ function in pdoc

To help you get started, we’ve selected a few pdoc examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github scikit-optimize / scikit-optimize / build_tools / travis / make_doc.py View on Github external
# Can we make a good faith attempt to support 2.6?
    # YES WE CAN!
    p = subprocess.Popen(cmd, stdin=subprocess.PIPE,
                         stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
    out = p.communicate()[0].strip().decode('utf-8')
    if p.returncode > 0:
        err = subprocess.CalledProcessError(p.returncode, cmd)
        err.output = out
        raise err
    if len(out) > 0:
        print(out)


if __name__ == '__main__':
    if args.version:
        print(pdoc.__version__)
        sys.exit(0)

    # We close stdin because some modules, upon import, are not very polite
    # and block on stdin.
    try:
        sys.stdin.close()
    except:
        pass

    if not args.http and args.module_name is None:
        _eprint('No module name specified.')
        sys.exit(1)
    if args.template_dir is not None:
        pdoc.tpl_lookup.directories.insert(0, args.template_dir)

    # If PYTHONPATH is set, let it override everything if we want it to.

pdoc

API Documentation for Python Projects

MIT-0
Latest version published 10 days ago

Package Health Score

90 / 100
Full package analysis