Skip to content
Browse files

Changed the way to generate module links in the html files

  • Loading branch information...
1 parent 4a8f14f commit 78d796d1f018bb66d986e73bc4641b6c0b372a55 @gpambrozio committed
Showing with 3 additions and 3 deletions.
  1. +3 −3 PythonDocs2DocSet/create_docset.py
View
6 PythonDocs2DocSet/create_docset.py
@@ -248,10 +248,10 @@ def find_existing_file(possible):
# As reported by Dash's author: Module references (added as categories)
# do not have proper anchor in the html files, so I have to add them.
- for module in soup.findAll("a", "reference", href=re.compile(r'^#module-.+$')):
+ for module in soup.findAll(["div", "span"], id=re.compile(r'^module-.+$')):
a_tag = soup.new_tag("a")
- a_tag["name"] = "//apple_ref/cpp/cat/%s" % module["href"][8:]
- module.parent.insert(0, a_tag)
+ a_tag["name"] = "//apple_ref/cpp/cat/%s" % module["id"][7:]
+ module.insert(0, a_tag)
if len(names) > 0:
tokens.write("<File path=\"%s\">\n" % href)

0 comments on commit 78d796d

Please sign in to comment.
Something went wrong with that request. Please try again.