~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/doc_generate/autodoc_man.py

  • Committer: Patch Queue Manager
  • Date: 2012-03-14 18:06:53 UTC
  • mfrom: (6503.1.1 bzr.dev)
  • Revision ID: pqm@pqm.ubuntu.com-20120314180653-s9xq11h0hmujalre
(jelmer) Prevent command description lines from being interpreted as a roff
 macro when they start with a dot. (Jelmer Vernooij)

Show diffs side-by-side

added added

removed removed

Lines of Context:
111
111
    doc = "%s\n" % (cmd.__doc__)
112
112
    doc = bzrlib.help_topics.help_as_plain_text(cmd.help())
113
113
 
 
114
    # A dot at the beginning of a line is interpreted as a macro.
 
115
    # Simply join lines that begin with a dot with the previous
 
116
    # line to work around this.
 
117
    doc = doc.replace("\n.", ".")
 
118
 
114
119
    option_str = ""
115
120
    options = cmd.options()
116
121
    if options: