File: saslman.py

package info (click to toggle)
cyrus-sasl2 2.1.27%2Bdfsg-2.1%2Bdeb11u1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 19,940 kB
  • sloc: ansic: 58,942; javascript: 8,745; sh: 4,843; java: 1,614; xml: 1,498; makefile: 1,265; python: 342; perl: 199
file content (25 lines) | stat: -rw-r--r-- 689 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
"""
    sphinxlocal.roles.saslman
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~

    Turn :saslman: links into manpage references to the cyrus sasl doc tree

    :version: 0.1
    :author: Nicola Nye <nicolan@fastmail.com>

    :copyright: Copyright 2007-2016 by the Sphinx team, see AUTHORS.
    :license: BSD, see LICENSE for details.
"""

from sphinx.errors import SphinxError
from docutils import nodes, utils
from docutils.parsers.rst.roles import set_classes
from string import Template
import re

def setup(app):
    app.add_crossref_type('saslman', 'saslman', '%s', nodes.generated)
    return

class CyrusManExtension(SphinxError):
        category = ':saslman: error'