pycco-docs / pycco

Literate-style documentation generator.

Home Page:https://pycco-docs.github.io/pycco/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for .h (C/C++ Header) files

sulphur2 opened this issue · comments

Thanks! For the excellent port. It works fantastic with various sources. However, when I try to generate docs for .h files, I get the following error:

[jupiter@localhost app]$ $pycco core/*.h
Traceback (most recent call last):
File "/usr/bin/pycco", line 9, in
load_entry_point('Pycco==0.3.0', 'console_scripts', 'pycco')()
File "/usr/lib/python2.6/site-packages/pycco/main.py", line 480, in main
process(sources, outdir=opts.outdir, preserve_paths=opts.paths)
File "/usr/lib/python2.6/site-packages/pycco/main.py", line 417, in process
next_file()
File "/usr/lib/python2.6/site-packages/pycco/main.py", line 411, in next_file
f.write(generate_documentation(s, preserve_paths=preserve_paths, outdir=outdir))
File "/usr/lib/python2.6/site-packages/pycco/main.py", line 46, in generate_documentation
sections = parse(source, fh.read())
File "/usr/lib/python2.6/site-packages/pycco/main.py", line 66, in parse
language = get_language(source)
File "/usr/lib/python2.6/site-packages/pycco/main.py", line 324, in get_language
return languages[ source[source.rindex("."):] ]
KeyError: '.h'

I think you were on an older version, I'm unable to recreate at this time. Likely this issue can be closed. Would you mind confirming @sulphur2 ?