Fix #1381 :rfc: and :pep: roles support custom link text

This commit is contained in:
tk0miya
2014-08-20 12:27:08 +09:00
parent f14f77688a
commit dd8a02d5e1
3 changed files with 26 additions and 14 deletions

View File

@@ -129,8 +129,12 @@ HTML_XPATH = {
(".//li/code/em/span[@class='pre']", '^i$'),
(".//a[@href='http://www.python.org/dev/peps/pep-0008']"
"[@class='pep reference external']/strong", 'PEP 8'),
(".//a[@href='http://www.python.org/dev/peps/pep-0008']"
"[@class='pep reference external']/strong", 'Python Enhancement Proposal #8'),
(".//a[@href='http://tools.ietf.org/html/rfc1.html']"
"[@class='rfc reference external']/strong", 'RFC 1'),
(".//a[@href='http://tools.ietf.org/html/rfc1.html']"
"[@class='rfc reference external']/strong", 'Request for Comments #1'),
(".//a[@href='objects.html#envvar-HOME']"
"[@class='reference internal']/code/span[@class='pre']", 'HOME'),
(".//a[@href='#with']"