public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: John MacFarlane <jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org>
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: BBCode support
Date: Fri, 8 Apr 2016 15:04:05 -0700	[thread overview]
Message-ID: <20160408220405.GD61469@MacBook-Air-2.local> (raw)
In-Reply-To: <081526dc-4cac-4a38-847b-1785bbfafd48-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>

+++ Frank Siebert [Apr 08 16 06:05 ]:
>   pandoc supports many formats, but one I miss is [1]BBCode, also known
>   as phpBB. It is widely used in forums.
>   Is there a particular reason why pandoc does not support it
>   out-of-the-box?

No!

>   I implemented a writer (but other writers exist,
>   e.g. [2]markdown2bbcode.hs), not yet pushed or forked in github. What
>   is necessary to include it into the official pandoc?

Easiest approach is to fork pandoc, create a local branch
that adds your writer, and send me a PR.  Then I can review
the code.

Things you'll need:

- the actual writer module,
  src/Text/Pandoc/Writers/BBCode.hs

- modify src/Text/Pandoc.hs to incorporate this

- add tests (at minimum, writer.bbcode generated from
  testsuite.native, and verified to be correct); you'll
  need to modify tests/Tests/Old.hs to make sure this is
  run.

- modify README to include BBCode as an output format.

- modify cabal file - add bbcode to formats in description,
  add the module to exposed modules, add the test files.


      parent reply	other threads:[~2016-04-08 22:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-08 13:05 Frank Siebert
     [not found] ` <081526dc-4cac-4a38-847b-1785bbfafd48-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2016-04-08 22:04   ` John MacFarlane [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160408220405.GD61469@MacBook-Air-2.local \
    --to=jgm-tvlzxgkolnx2fbvcvol8/a@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).