public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* Using Pandoc with m4
@ 2016-11-12 12:42 Alec Clews
       [not found] ` <8b828e5b-a178-4974-ac8e-46c34790e848-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Alec Clews @ 2016-11-12 12:42 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 1179 bytes --]

I thought people might be interested in how I've used Pandoc and the m4 
macro processor together recently

I wrote an article about using Git; with lots of examples, the output from 
running the examples and various diagrams to illustrate the effect of the 
examples.

So I wrote some small (but complex) m4 macros to execute the various 
example commands and turn the output into Pandoc content for processing 
inline with the rest of my writing.

You can see the input files here

https://github.com/alecthegeek/version-control-basics

Big thanks to John for creating such an awesome tool as Pandoc.





-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/8b828e5b-a178-4974-ac8e-46c34790e848%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 1781 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Using Pandoc with m4
       [not found] ` <8b828e5b-a178-4974-ac8e-46c34790e848-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2016-11-12 15:28   ` Simon Michael
  2016-11-13 12:11     ` BP Jonsson
  0 siblings, 1 reply; 6+ messages in thread
From: Simon Michael @ 2016-11-12 15:28 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

On 11/12/16 4:42 AM, Alec Clews wrote:
> I thought people might be interested in how I've used Pandoc and the m4
> macro processor together recently
>
> I wrote an article about using Git; with lots of examples, the output from
> running the examples and various diagrams to illustrate the effect of the
> examples.
>
> So I wrote some small (but complex) m4 macros to execute the various
> example commands and turn the output into Pandoc content for processing
> inline with the rest of my writing.
>
> You can see the input files here
>
> https://github.com/alecthegeek/version-control-basics
>
> Big thanks to John for creating such an awesome tool as Pandoc.
Hi Alec,

thanks for sharing this! I am reading with interest and learning useful 
things.

Here's my own m4 & pandoc setup:

utils: https://github.com/simonmichael/hledger/blob/master/doc/lib.m4
a doc: 
https://raw.githubusercontent.com/simonmichael/hledger/master/hledger-ui/doc/hledger-ui.1.m4.md
makefile: https://github.com/simonmichael/hledger/blob/master/Shake.hs)

I'm new to m4, but I find it's power seductive and complementary to 
pandoc. I could do some or all of this (conditionals, macros..) with 
pandoc filters, but it felt like more boilerplate and more work.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Using Pandoc with m4
  2016-11-12 15:28   ` Simon Michael
@ 2016-11-13 12:11     ` BP Jonsson
       [not found]       ` <CAFC_yuQLQrOdfAT=nmya26GROZAj5UA1=ansDkvDzWkD3p8rPw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: BP Jonsson @ 2016-11-13 12:11 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

[-- Attachment #1: Type: text/plain, Size: 3763 bytes --]

I looked at m4 earlier this year and found it interesting, but as it
apparently lacks UTF-8 support I thought it would be of limited usefulness
to me. Does anyone know a macro processor which does support UTF-8?

lördag 12 november 2016 skrev Simon Michael <simon-jbxitMBJ2LLQT0dZR+AlfA@public.gmane.org>:

> On 11/12/16 4:42 AM, Alec Clews wrote:
>
>> I thought people might be interested in how I've used Pandoc and the m4
>> macro processor together recently
>>
>> I wrote an article about using Git; with lots of examples, the output from
>> running the examples and various diagrams to illustrate the effect of the
>> examples.
>>
>> So I wrote some small (but complex) m4 macros to execute the various
>> example commands and turn the output into Pandoc content for processing
>> inline with the rest of my writing.
>>
>> You can see the input files here
>>
>> https://github.com/alecthegeek/version-control-basics
>>
>> Big thanks to John for creating such an awesome tool as Pandoc.
>>
> Hi Alec,
>
> thanks for sharing this! I am reading with interest and learning useful
> things.
>
> Here's my own m4 & pandoc setup:
>
> utils: https://github.com/simonmichael/hledger/blob/master/doc/lib.m4
> a doc: https://raw.githubusercontent.com/simonmichael/hledger/maste
> r/hledger-ui/doc/hledger-ui.1.m4.md
> makefile: https://github.com/simonmichael/hledger/blob/master/Shake.hs)
>
> I'm new to m4, but I find it's power seductive and complementary to
> pandoc. I could do some or all of this (conditionals, macros..) with pandoc
> filters, but it felt like more boilerplate and more work.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit https://groups.google.com/d/ms
> gid/pandoc-discuss/o07cf5%24lo0%241%40blaine.gmane.org.
> For more options, visit https://groups.google.com/d/optout.
>


-- 

------------------------------
SavedURI :Show URLShow URLSavedURI :
SavedURI :Hide URLHide URLSavedURI :
https://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvwhttps://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvw
<https://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvw>
<https://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvw>
------------------------------

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CAFC_yuQLQrOdfAT%3Dnmya26GROZAj5UA1%3DansDkvDzWkD3p8rPw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #2: Type: text/html, Size: 5416 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Using Pandoc with m4
       [not found]       ` <CAFC_yuQLQrOdfAT=nmya26GROZAj5UA1=ansDkvDzWkD3p8rPw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2016-11-13 21:57         ` Alec Clews
  2016-11-13 22:26         ` Joost Kremers
  1 sibling, 0 replies; 6+ messages in thread
From: Alec Clews @ 2016-11-13 21:57 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

[-- Attachment #1: Type: text/plain, Size: 5751 bytes --]

Apparently the GCC C preprocessor (cpp) can support utf-8


https://gcc.gnu.org/onlinedocs/cpp/Character-sets.html


I believe the cpp in CLANG does as well?



On 13/11/16 23:11, BP Jonsson wrote:
> I looked at m4 earlier this year and found it interesting, but as it
> apparently lacks UTF-8 support I thought it would be of limited
> usefulness to me. Does anyone know a macro processor which does
> support UTF-8?
>
> lördag 12 november 2016 skrev Simon Michael <simon-jbxitMBJ2LLQT0dZR+AlfA@public.gmane.org
> <mailto:simon-jbxitMBJ2LLQT0dZR+AlfA@public.gmane.org>>:
>
>     On 11/12/16 4:42 AM, Alec Clews wrote:
>
>         I thought people might be interested in how I've used Pandoc
>         and the m4
>         macro processor together recently
>
>         I wrote an article about using Git; with lots of examples, the
>         output from
>         running the examples and various diagrams to illustrate the
>         effect of the
>         examples.
>
>         So I wrote some small (but complex) m4 macros to execute the
>         various
>         example commands and turn the output into Pandoc content for
>         processing
>         inline with the rest of my writing.
>
>         You can see the input files here
>
>         https://github.com/alecthegeek/version-control-basics
>         <https://github.com/alecthegeek/version-control-basics>
>
>         Big thanks to John for creating such an awesome tool as Pandoc.
>
>     Hi Alec,
>
>     thanks for sharing this! I am reading with interest and learning
>     useful things.
>
>     Here's my own m4 & pandoc setup:
>
>     utils:
>     https://github.com/simonmichael/hledger/blob/master/doc/lib.m4
>     <https://github.com/simonmichael/hledger/blob/master/doc/lib.m4>
>     a doc:
>     https://raw.githubusercontent.com/simonmichael/hledger/master/hledger-ui/doc/hledger-ui.1.m4.md
>     <https://raw.githubusercontent.com/simonmichael/hledger/master/hledger-ui/doc/hledger-ui.1.m4.md>
>     makefile:
>     https://github.com/simonmichael/hledger/blob/master/Shake.hs
>     <https://github.com/simonmichael/hledger/blob/master/Shake.hs>)
>
>     I'm new to m4, but I find it's power seductive and complementary
>     to pandoc. I could do some or all of this (conditionals, macros..)
>     with pandoc filters, but it felt like more boilerplate and more work.
>
>
>     -- 
>     You received this message because you are subscribed to the Google
>     Groups "pandoc-discuss" group.
>     To unsubscribe from this group and stop receiving emails from it,
>     send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>     To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>     To view this discussion on the web visit
>     https://groups.google.com/d/msgid/pandoc-discuss/o07cf5%24lo0%241%40blaine.gmane.org
>     <https://groups.google.com/d/msgid/pandoc-discuss/o07cf5%24lo0%241%40blaine.gmane.org>.
>     For more options, visit https://groups.google.com/d/optout
>     <https://groups.google.com/d/optout>.
>
>
>
> -- 
>
> ------------------------------------------------------------------------
> SavedURI :Show URLShow URLSavedURI :
> SavedURI :Hide URLHide URLSavedURI :
> https://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvwhttps://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvw
> <https://mail.google.com/_/scs/mail-static/_/js/k=gmail.main.sv.G3GZFwvcniQ.O/m=m_i,t,it/am=fUAcTAoZawdGHAZ2YD-g9N_f7LL4CX7WlSgHQKgABHaCv9kToPiBD8qOMw/rt=h/d=1/rs=AItRSTO5CF1YB_frDRXLXTeUsQ1zItcBvw>
> ------------------------------------------------------------------------
>
> -- 
> You received this message because you are subscribed to the Google
> Groups "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> <mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.
> To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> <mailto:pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pandoc-discuss/CAFC_yuQLQrOdfAT%3Dnmya26GROZAj5UA1%3DansDkvDzWkD3p8rPw%40mail.gmail.com
> <https://groups.google.com/d/msgid/pandoc-discuss/CAFC_yuQLQrOdfAT%3Dnmya26GROZAj5UA1%3DansDkvDzWkD3p8rPw%40mail.gmail.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.

-- 

Alec Clews
Personal <alec.clews-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>             Melbourne, Australia.
Jabber:  alecclews-/eSpBmjxGS63Zbb/xt2tYQ@public.gmane.org             PGPKey ID: 0x9BBBFC7C
blog:http://alecthegeek.github.io/

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/4f77b0cb-3a7b-b34d-9445-f33f5f5a7cbe%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #2: Type: text/html, Size: 8482 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Using Pandoc with m4
       [not found]       ` <CAFC_yuQLQrOdfAT=nmya26GROZAj5UA1=ansDkvDzWkD3p8rPw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  2016-11-13 21:57         ` Alec Clews
@ 2016-11-13 22:26         ` Joost Kremers
       [not found]           ` <87y40n3tkv.fsf-97jfqw80gc6171pxa8y+qA@public.gmane.org>
  1 sibling, 1 reply; 6+ messages in thread
From: Joost Kremers @ 2016-11-13 22:26 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw


On Sun, Nov 13 2016, BP Jonsson wrote:
> Does anyone know a macro processor which does support UTF-8?

Emacs (ducks & runs).

-- 
Joost Kremers
Life has its moments


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Using Pandoc with m4
       [not found]           ` <87y40n3tkv.fsf-97jfqw80gc6171pxa8y+qA@public.gmane.org>
@ 2016-11-14 15:41             ` Bruce
  0 siblings, 0 replies; 6+ messages in thread
From: Bruce @ 2016-11-14 15:41 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 1133 bytes --]



On Sunday, November 13, 2016 at 2:26:13 PM UTC-8, Joost wrote:
>
>
> On Sun, Nov 13 2016, BP Jonsson wrote: 
> > Does anyone know a macro processor which does support UTF-8? 
>
>
I have been using filepp (http://www-users.york.ac.uk/~dm26/filepp/)    The 
website says:

Also, as filepp is written in Perl, it is 8-bit clean and so works on any 
character set, not just ASCII characters. filepp is also customisable and 
hopefully more user friendly than cpp.

On another note, pandoc is great!   Thanks to everyone (especially John) 
for your work.

-Bruce 

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/2064f5a0-6a3f-4c5f-a820-94269dc93f4b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 2109 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-11-14 15:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-12 12:42 Using Pandoc with m4 Alec Clews
     [not found] ` <8b828e5b-a178-4974-ac8e-46c34790e848-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2016-11-12 15:28   ` Simon Michael
2016-11-13 12:11     ` BP Jonsson
     [not found]       ` <CAFC_yuQLQrOdfAT=nmya26GROZAj5UA1=ansDkvDzWkD3p8rPw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-11-13 21:57         ` Alec Clews
2016-11-13 22:26         ` Joost Kremers
     [not found]           ` <87y40n3tkv.fsf-97jfqw80gc6171pxa8y+qA@public.gmane.org>
2016-11-14 15:41             ` Bruce

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).