Created by James Westby on 2009-08-04 and last modified on 2009-08-04
Get this branch:
bzr branch lp:ubuntu/karmic/pandoc
Members of Ubuntu branches can upload to this branch. Log in for directions.

Related bugs

Related blueprints

Branch information

Ubuntu branches
Review team:
Ubuntu Development Team

Recent revisions

6. By Iain Lane on 2009-08-04

* Non-maintainer upload.
* Text/Pandoc/Definition.hs: Patch file to fix Haddock parse
  error which led to FTBFS. Move annotation of type synonym to before the
  definition. (Closes: #536960)

5. By Iain Lane on 2009-08-04

debian/patches/haddock_type.patch: Add new patch to fix Haddock parse
error which led to FTBFS. Move annotation of type synonym to before the

4. By Iain Lane on 2009-01-25

No-change rebuild to pick up new GHC (LP: #320946).

3. By Recai Oktas on 2008-02-09

[ Recai Oktaş ]

* Debian packaging changes:

  + Remove bogus dependency on libghc6-uulib-dev.

2. By Recai Oktas on 2007-10-07

[ John MacFarlane ]

* Simplified parsing of reference keys and notes in markdown and RST
  readers: The Reference data structure from Text.Pandoc.Shared is no
  longer needed, since referenceKey and noteBlock parses return strings
  (as many blank lines as were occupied by the key or note) and update
  state themselves. getPosition and setPosition are now used to ensure
  that error messages will give the correct line number. This yields
  cleaner (and slightly faster) code, with more accurate parsing error

* Added new Math inline element:

  + Markdown and LaTeX readers now convert TeX math into Math elements,
    not TeX.
  + This allows math to be treated differently from raw TeX in output.
    TeX elements are no longer printed in output formats other than
    Markdown, LaTeX, and ConTeXt. But Math elements are always printed.

* New default handling of math in writers:

  + New module Text.Pandoc.Readers.TeXMath exports readTeXMath, which
    parses raw TeX math and outputs a string of Pandoc inlines that
    tries to render it as far as possible using unicode characters,
    lapsing into literal TeX when needed.
  + readTeXMath is now used for default HTML output in HTML, S5, RTF,
    and Docbook, if no other method for displaying math in HTML is
    specified. Enclosing $'s are no longer printed by default.
  + By default, math is put inside <span class="math">. This way it can be
    distinguished from the surrounding text, e.g. put in a different

* New --gladtex and --mimetex options for display of math in HTML:

  + If --gladtex is specified, math is output between <eq> tags, so
    it can be processed by gladTeX.
  + If --mimetex is specified, math is put in <img> tags with a link
    to the mimetex CGI script (or any other script that takes TeX math
    as input and outputs an image). The URL of the script may be
    specified, but defaults to /cgi-bin/mimetex.cgi.
  + HTMLMathMethod structure in WriterOptions keeps track of how to
    display math in HTML output.
  + Updated README with a description of the four options for displaying
    math in HTML.

* HTML reader:

  + Fixed bug: parser for minimized attributes should not swallow
    trailing spaces.
  + Simplified HTML attribute parsing.
  + Changed parsing of code blocks in HTML reader: <code> tag is no
    longer needed. <pre> suffices. All HTML tags in the code block
    (e.g. for syntax highlighting) are skipped, because they are not
    portable to other output formats. A <code>...</code> block not
    surrounded by <pre> now counts as inline HTML, not a code block.
  + Remove just one leading and one trailing newline from contents of
    <pre>...</pre> in codeBlock parser.

* Markdown reader:

  + Removed support for box-style block quotes.
  + Require space before title in links and references.
    This fixes a bug in parsing URLs like http://silly/url(withparen).
  + Improved and simplified setextHeader parser.
  + Fixed logic in smart quote parsing, adding some needed 'try'
  + Fixed smart quote parsing so that unicode characters 8216 and 8217
    are recognized as single quotes, and 8220 and 8221 as double quotes.

* RST reader:

  + Fixed bug in parsing of code blocks. Previously a full tab indent
    was required, but RST allows code to be indented any amount.
    Resolves Issue #27.
  + Allow field lists to be indented.
  + Parse the contents of field lists instead of treating as a raw string.
  + Represent field lists as definition lists instead of blockquotes.
  + Fixed bug in which metadata would be overridden if the document
    contained multiple field lists.
  + Parse fields associated with '.. image::' blocks, and use 'alt'
    field, if given, for image alt and title attributes.

* LaTeX reader:

  + Modified specialChar so that '"' characters are parsed.
  + Fixed a bug in parsing of \[ \] math blocks (thanks to Mark Kalderon).

* HTML writer:

  + Changes in handling of math (see above).
  + Don't produce HTML for table of contents if there are
    no headers. (This would be an empty list, which is invalid XHTML.)

* Markdown writer:

  + Don't print title attribute if title is empty. (This differs from
    the behavior of Markdown.pl, and agrees with PHP Markdown. But John
    Gruber has indicated that he prefers this behavior.) Adjusted test
    suite accordingly.
  + Fixed incorrect line wrapping in paragraphs including hard line
    breaks. Resolves Issue #25.
  + Fixed bug in markdown writer: If an ordered list item began with
    a marker greater than 3 characters in width, and the item took more
    than one line, it would appear on the line after the list marker,

            My list item.

    Now it works as follows:

        (12) My list item.

* RST writer

  + Fixed bug in RST writer's handling of ordered lists. Previously,
    list items with multiple lines would not always line up with
    single-line list items. Now, list items are nested the length of
    the list marker + 1. This looks better and ensures that list items
    all line up. (Note that list markers are padded to the length of
    the longest list marker in the series.)
  + Use 3-space indent for unordered lists.
  + If label for a link reference contains a colon, surround it by `
    signs so it won't be interpreted as the end of the link label.

* LaTeX writer:

  + Cleaner output for footnotes. Footnotes now always begin on a new
    line, and the final } is on a line by itself only when it needs to
    be (i.e. only when the note ends with a Verbatim environment).
  + Added writer options to state, so state doesn't need to be passed as
    a parameter.
  + Text wrapping now provided, using wrapTeXIfNeeded.

* ConTeXt writer: many improvements for more idiomatic ConTeXt output
  (thanks to Idris Samawi Hamid for suggestions).

  + PrettyPrint module now used for output.
  + Writer options are now in state, so they don't have to be passed as
    a parameter.
  + Text wrapping now provided, using wrapTeXIfNeeded.
  + Better treatment of footnotes: footnotes are always on lines by
    themselves, and the final } is on a line by itself only when
    it needs to be (after \stoptyping).
  + Use \subject, \subsubject, ... or \section, \subsection, ... for headings,
    depending on whether --number-sections option is selected.
  + Extra blank line inserted after \stopitemize
  + Use new, "official" definition of blockquote environment. Also, use
    blank line after \startblockquote to balance blank line at the end.
  + Both itemized and enumerated lists are now generated using
    \start-stopitemize, with appropriate options. Removed definitions
    of ltxenum and ltxitem, which are no longer needed. Provided
    defaults for itemized lists in the preamble. State keeps track of
    ordered list level, so that when default numbering is specified,
    the appropriate scheme can be used.
  + Changed \useurl to \useURL.
  + Changed link color from red to blue.
  + Use \subsubsubsubsection etc., since these are supported
    (up to at least sub x 5).

* Text.Pandoc.Shared:

  + Save and restore position in parseFromString, so that accurate
    error messages can be given.
  + Improved efficiency of romanNumeral parser.
  + Added wrappedTeX and wrapTeXIfNeeded functions. These ensure
    that footnotes occur on lines by themselves (to make them
    easier to see and move) and do not screw up line wrapping.

* Text.Pandoc.UTF8: modified fromUTF8 to strip out the BOM
  if present. Windows Notepad and other applications insert a
  BOM at the beginning of a UTF8 file.

* Main.hs (tabFilter): Treat '\r' at end of line as newline (in
  addition to "\r\n" and '\n').

* Added a writer option for wrapped text and a command-line option
  '--no-wrap', which disables text wrapping and minimizes whitespace
  in HTML. (Resolves Issue #26.)

  + Added support for '--no-wrap' to Main.hs.
  + Added wrapIfNeeded function to Text.Pandoc.Shared.
  + Use wrapIfNeeded instead of wrapped in the RST, Man, Docbook, and
    Markdown writers.
  + Added render and renderFragment helpers to HTML writer.

* Modified html2markdown to run tidy only if the HTML cannot be
  parsed. Previously html2markdown piped all input through tidy
  before passing it to pandoc. This caused problems on certain pages
  (e.g. http://daringfireball.com/markdown) which have well-formed
  XHTML that causes tidy to choke. The solution is to pipe through
  tidy only if pandoc cannot parse the input by itself. This means
  that a temp file is now always used, even when input comes from a
  local file or standard input.

* Removed 'version' constant from Main.hs; added 'pandocVersion' to
  Text.Pandoc library.

* pandoc.cabal:

  + Modified to work with GHC 6.8 and Cabal configurations. (For GHC
    6.8, pretty and containers must be added to Build-Depends, and it
    is desirable to use the -O2 compiler option.) Cabal configurations
    allows one to select options depending on the compiler version.
    For GHC 6.6, the splitBase option can be disabled.
  + pandoc.cabal.ghc66 is provided for users with older versions of
    Cabal, which do not support configurations.
  + Use Ghc-Prof-Options to ensure that '-auto-all' is used when
    '--enable-(executable|library)-profiling' is specified. Updated
    PROFILING instructions accordingly.

* Makefile:

  + Makefile now checks GHC version. If GHC is 6.6, pandoc.cabal.ghc66
    is copied to pandoc.cabal, and the old pandoc.cabal is copied
    to pandoc.cabal.orig. Otherwise, pandoc.cabal is copied to
    pandoc.cabal.orig but otherwise unmodified. This way, the Makefile
    will work properly with either GHC 6.6 or 6.8.
  + Changed BUILDCONF to point to dist/setup-config, not .setup-config.
    This is where current versions of Cabal put it.
  + Added $(BUILDCMD) target, so setup doesn't get compiled every time.
  + Removed dependency of templates on ./templates, which is circular
    now that templates is a subdirectory of the top-level.

* MacPorts Portfile:

  + Modified to install the pandoc library in addition to programs.
  + Installation must be done manually rather than using Makefile's
  + Note that the library must be registered in the activate phase,
    after the library files have been copied out of the destroot.
    Cabal generates a 'register.sh' script that will do this.

* debian/control: Added libghc6-network-dev, libghc6-xhtml-dev, and
  libghc6-mtl-dev as dependencies for libghc6-pandoc-dev.
  Closes: #445235

* debian/rules: Converted to UTF-8.

* Changed pandoc home page to http://johnmacfarlane.net/pandoc/.

* Updated ASCIIMathML.js to latest version.

* Directory structure:

  + Moved everything from src into the top-level directory.
  + Changed references to source directory in Makefile and
  + Moved ASCIIMathML.js, headers, and ui into templates directory.
  + Modified fillTemplates.pl to reflect new paths.

[ Recai Oktaş ]

* Makefile: Fixed the issue of having two copies of the library
  documentation under some usage scenarios.

* Replaced 'ghc' with '$(GHC)' in Makefile, and made GHC
  and GHC_PKG configurable through the environment, to support
  unusual ghc installations. For example:
  GHC=/opt/ghc/bin/ghc GHC_PKG=/opt/ghc/bin/ghc-pkg make

1. By Recai Oktas on 2007-09-03

[ John MacFarlane ]

* Fixed bug in HTML writer: when --toc was used, anchors were put around
  headers, which is invalid XHTML (block content within inline element).
  Now the anchors are put inside the header tags. Resolves Issue #23.

* Added xmlns attribute to html element in html writer tests.
  This attribute is added by more recent versions of the
  xhtml library (>= 3000), and is required for valid XHTML.

[ Recai Oktaş ]

* On configure, compile 'Setup.hs' to 'setup' and use 'setup' as the build
  command instead of 'runhaskell', which, on some platforms (such as s390,
  alpha, m68k), throws the following error:

      runhaskell Setup.hs configure --prefix=/usr
      ghc-6.6.1: not built for interactive use

  This causes a serious FTBFS bug. Closes: #440668.

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
Stacked on:
This branch contains Public information 
Everyone can see this information.