Rev 6504: (jelmer) Prevent command description lines from being interpreted as a roff in file:///srv/pqm.bazaar-vcs.org/archives/thelove/bzr/%2Btrunk/

Patch Queue Manager pqm at pqm.ubuntu.com
Wed Mar 14 18:06:54 UTC 2012


At file:///srv/pqm.bazaar-vcs.org/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 6504 [merge]
revision-id: pqm at pqm.ubuntu.com-20120314180653-s9xq11h0hmujalre
parent: pqm at pqm.ubuntu.com-20120314160616-62773rqsd2btxrxu
parent: jelmer at samba.org-20120314165827-bit49al860i9zxsz
committer: Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Wed 2012-03-14 18:06:53 +0000
message:
  (jelmer) Prevent command description lines from being interpreted as a roff
   macro when they start with a dot. (Jelmer Vernooij)
modified:
  bzrlib/doc_generate/autodoc_man.py bzrman.py-20050601153041-0ff7f74de456d15e
  doc/en/release-notes/bzr-2.6.txt bzr2.6.txt-20120116134316-8w1xxom1c7vcu1t5-1
=== modified file 'bzrlib/doc_generate/autodoc_man.py'
--- a/bzrlib/doc_generate/autodoc_man.py	2012-03-14 10:34:27 +0000
+++ b/bzrlib/doc_generate/autodoc_man.py	2012-03-14 16:58:27 +0000
@@ -111,6 +111,11 @@
     doc = "%s\n" % (cmd.__doc__)
     doc = bzrlib.help_topics.help_as_plain_text(cmd.help())
 
+    # A dot at the beginning of a line is interpreted as a macro.
+    # Simply join lines that begin with a dot with the previous
+    # line to work around this.
+    doc = doc.replace("\n.", ".")
+
     option_str = ""
     options = cmd.options()
     if options:

=== modified file 'doc/en/release-notes/bzr-2.6.txt'
--- a/doc/en/release-notes/bzr-2.6.txt	2012-03-14 15:26:01 +0000
+++ b/doc/en/release-notes/bzr-2.6.txt	2012-03-14 16:58:27 +0000
@@ -64,6 +64,10 @@
 
 .. Improved or updated documentation.
 
+* Prevent lines of command descriptions starting with a dot to
+  accidentally be interpreted as a roff macro in bzr(1).
+  (Jelmer Vernooij, #711079)
+
 * Properly format apostrophes in manual page. (Jelmer Vernooij, #234771)
 
 API Changes




More information about the bazaar-commits mailing list