From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/14879 Path: news.gmane.org!not-for-mail From: =?UTF-8?Q?JDani_Jim=C3=A9nez?= Newsgroups: gmane.text.pandoc Subject: Re: Automating markdown to odt with fields Date: Fri, 29 Apr 2016 01:59:50 -0700 (PDT) Message-ID: References: <7608243e-3f15-48de-9230-00b78127246e@googlegroups.com> <1a7138b7-aa6a-4873-b214-9644944c75c6@googlegroups.com> <20160426212236.GA35686@protagoras.berkeley.edu> <59292504-c115-4935-b7e2-004c0c875289@googlegroups.com> <20160427172120.GA40999@MacBook-Air-2.local> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_182_2101390056.1461920390247" X-Trace: ger.gmane.org 1461920406 3877 80.91.229.3 (29 Apr 2016 09:00:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 29 Apr 2016 09:00:06 +0000 (UTC) To: pandoc-discuss Original-X-From: pandoc-discuss+bncBDL6Z34U5MNRBBWFRS4QKGQETR7UHXQ-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Fri Apr 29 10:59:53 2016 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane.org Original-Received: from mail-qg0-f58.google.com ([209.85.192.58]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aw4HA-0000Yo-6q for gtp-pandoc-discuss@m.gmane.org; Fri, 29 Apr 2016 10:59:52 +0200 Original-Received: by mail-qg0-f58.google.com with SMTP id f74sf21968815qge.1 for ; Fri, 29 Apr 2016 01:59:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20120806; h=sender:date:from:to:message-id:in-reply-to:references:subject :mime-version:x-original-sender:reply-to:precedence:mailing-list :list-id:x-spam-checked-in-group:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=T1atFGFvucc4els9cB+64sNR0glZjasYYRh7PX1VGTk=; b=boWkf/hOXbRugKbd9vULBaGWAJLgGHkkApGCiabMZFHoLnreT2Q3driJ6aZXwAd2Yk 0gKefz+jBuPlkPhR04X1ZV8wqAMiIGwjNWnZKADCFQ6B+1UH3dF2lQQa0XDyTezKSNXl cLDeVrT9W+dnv8Q/JyBafaFX2ygOnZg3C6Q/j6cUHumaoVAXx9AZZPsjjETsTbaOW0e6 vA2iBeDcWRkp/wwimGwPzp3t+UrTtTrNyVCR9UghKfmnKPXBBkjzAVYUt3oOyWzusgDj uLcebsjSdWvAjTHsiqElSBUmpSo/zGITZ/tMETZh8SV7qq/nifnyO6VobI803FeAoLkL d6Pg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:message-id:in-reply-to:references:subject:mime-version :x-original-sender:reply-to:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=T1atFGFvucc4els9cB+64sNR0glZjasYYRh7PX1VGTk=; b=oHb7fnlaojxrHHTIGc5mG9gDc4ZXxQ4AK5yv5bAsjcx6N/VXDvIr2eyDV+EluwPdUk p4PZbm55Nrv3P5i9Fb6Bo1BiMgHhWL/RiT6qjLXnNg/JeU1sKoOBjpzG7m+EQZ633B9y xR/YD2jyUJ9F5UgJ0KWDbnPqATi3g+oRt7WcRTh+HVqXVrIqrNa/ealmTUkNtLHsSg+W CbmatfwykdWQfllqR10sDHY5EBa8Mvu1AP8R55p2A3Y9J0ssYQIbYadfRRVnrvryNITW Gdd1AjT+VGV+QGfEH6UxhNuiyp370NO3VZkNsAPqPZeAPlTlxEWIP81AMsspEjdn3eau pd6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=sender:x-gm-message-state:date:from:to:message-id:in-reply-to :references:subject:mime-version:x-original-sender:reply-to :precedence:mailing-list:list-id:x-spam-checked-in-group:list-post :list-help:list-archive:list-subscribe:list-unsubscribe; bh=T1atFGFvucc4els9cB+64sNR0glZjasYYRh7PX1VGTk=; b=Z5RtPFd8XLHV5dE9PNv5u3X9XUYl+cNe71VtGV18QWESC9rdFnRbn9y0D30z0dGbrv 8cAi7Nj5HsYeBJhyETLq7RGz9sD0M8P0snEY0VbFMgMNZ/29B7PCrgfmyhaiudRxa1Oe RuX3kYU/Pz8gkX5uZU/B4WtqKKWzVgnvNyXNC7rsRk6AiwMUYcQizkmUQboargSfx7VD xlyxA21JN5nCYQakDLcsYZXDDZNXGsCoXZMAWlQMnl4smUvh2l+XUxp/I9hisZ9e0+7I vTbhKXusQr5iylJk9m/a7UWXR6IPXOVAk22adRWiMVO7IBWwPGf7nZt5m5QQ1PKKmkgG 2yYg== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOPr4FXe6/Ul6LStXLARpjlwU7Hyiy54bVurc+SW0abNu2jPCJzO8UdROlvK8J9LFM4GFA== X-Received: by 10.157.3.52 with SMTP id 49mr248623otv.19.1461920391393; Fri, 29 Apr 2016 01:59:51 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 10.182.50.195 with SMTP id e3ls362580obo.56.gmail; Fri, 29 Apr 2016 01:59:50 -0700 (PDT) X-Received: by 10.182.225.5 with SMTP id rg5mr250426obc.4.1461920390652; Fri, 29 Apr 2016 01:59:50 -0700 (PDT) In-Reply-To: <20160427172120.GA40999-jF64zX8BO091tJRe0FUodcM6rOWSkUom@public.gmane.org> X-Original-Sender: jdjp83-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Spam-Checked-In-Group: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.org gmane.text.pandoc:14879 Archived-At: ------=_Part_182_2101390056.1461920390247 Content-Type: multipart/alternative; boundary="----=_Part_183_677372410.1461920390249" ------=_Part_183_677372410.1461920390249 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Yeah! I did it and it's, but formatting fully working. Thanks! Now I'm getting some formatting issues, so I'll open a new thread for it. Thanks!! El mi=C3=A9rcoles, 27 de abril de 2016, 19:21:35 (UTC+2), John MacFarlane= =20 escribi=C3=B3: > > Well, you could always use python or something instead of=20 > bash; that would allow you to put arbitrary string values=20 > in as command line arguments without worrying about escapes=20 > and quoting.=20 > > +++ JDani Jim=C3=A9nez [Apr 27 16 05:00 ]:=20 > > This solution is not working... The -V $(pandoc...) commands output= =20 > > contains characters that are control characters for bash, so the=20 > > command cannot be launched like that.=20 > > Example:=20 > > $ pandoc --template odt.template main.md -t opendocument -o my.odt -V= =20 > > s1=3D$( pandoc -t opendocument -f markdown sections/section1.md ) -V= =20 > > s2=3D$( pandoc -t opendocument -f markdown sections/section2.md ) -V= =20 > > s3=3D$( pandoc -t opendocument -f markdown sections/section3.md )=20 > > pandoc: text:style-name=3D"Heading_20_1": openFile: does not exist (N= o=20 > > such file or directory)=20 > > The same, but with the debug enabled:=20 > > $ set -x=20 > > $ pandoc --template odt.template main.md -t opendocument -o my.odt -V= =20 > > s1=3D$( pandoc -t opendocument -f markdown sections/section1.md ) -V= =20 > > s2=3D$( pandoc -t opendocument -f markdown sections/section2.md ) -V= =20 > > s3=3D$( pandoc -t opendocument -f markdown sections/section3.md )=20 > > ++ pandoc -t opendocument -f markdown sections/section1.md=20 > > ++ pandoc -t opendocument -f markdown sections/section2.md=20 > > ++ pandoc -t opendocument -f markdown sections/section3.md=20 > > + pandoc --template odt.template main.md -t opendocument -o my.odt -V= =20 > > 's1=3D > 'text:outline-level=3D"1">Encabezado' '1' ' > 'text:style-name=3D"Heading_20_2"' 'text:outline-level=3D"2">Encabeza= do'=20 > > '2' ' > 'text:outline-level=3D"3">Encabezado' '3' ' > 'text:style-name=3D"L1">' '' ' > 'text:style-name=3D"P1">lista' item '1' ''= =20 > > '' 'lista' item=20 > > '2' '' '' ' > 'text:style-name=3D"P1">lista' item '3' ''= =20 > > '' -V 's2=3DPr= ueba'=20 > > de texto en 'Negrita'= ,=20 > > 'cursiva,' ' > 'text:style-name=3D"T3">tachado' y ' > 'text:style-name=3D"T4">mezcla > 'text:style-name=3D"T5">' ' > 'text:style-name=3D"T6">de 'text:style-name=3D"T7">'=20 > > ' > 'text:style-name=3D"T8">negrita > 'text:style-name=3D"T9">' ' > 'text:style-name=3D"T10">y > 'text:style-name=3D"T11">' ' > 'text:style-name=3D"T12">negrita > 'text:style-name=3D"T13">' ' > 'text:style-name=3D"T14">cursiva' -V 's3=3D > 'text:style-name=3D"Text_20_body">Prueba' de link: ' > 'xlink:type=3D"simple"' 'xlink:href=3D"https://www.google.com"'=20 > > 'office:name=3D"">I'\''m'= an=20 > > inline-style link with 'title' Prueba de imagen:= =20 > > ' > 'xlink:href=3D"deloitte.jpg"' 'xlink:type=3D"simple"' 'xlink:show=3D"= embed"'=20 > > 'xlink:actuate=3D"onLoad"' '/>' Prueba de 'c=C3=B3digo'=20 > > 'Prueba' de 'c=C3=B3digo'= =20 > > pandoc: text:style-name=3D"Heading_20_1": openFile: does not exist (N= o=20 > > such file or directory)=20 > > I tryed these ways to get=20 > > * Using quotes and scaping quotes in the output of pandoc variable= =20 > > commands. Like this=20 > >=20 > > pandoc \=20 > > --template odt.template \=20 > > main.md \=20 > > -o my.odt \=20 > > -V s1=3D"$( pandoc -t opendocument -f markdown sections/section1.md = |=20 > > sed 's/"/\\"/g')" \=20 > > -V s2=3D"$( pandoc -t opendocument -f markdown sections/section2.md = |=20 > > sed 's/"/\\"/g')" \=20 > > -V s3=3D"$( pandoc -t opendocument -f markdown sections/section3.md = |=20 > > sed 's/"/\\"/g')"=20 > > Result: Malformed odt. Quotes keep scaped in contet.xml=20 > > * A three steps procedure=20 > >=20 > > * Compose an xml opendocument file, with quotes scaped=20 > > * Remove backslashes, unscape quotes=20 > > * Generate the odt=20 > >=20 > > $ pandoc \=20 > > --template odt.template \=20 > > main.md \=20 > > -t opendocument \=20 > > -o my.odt.xml \=20 > > -V s1=3D"$( pandoc -t opendocument -f markdown sections/section1.md = |=20 > > sed 's/"/\\"/g')" \=20 > > -V s2=3D"$( pandoc -t opendocument -f markdown sections/section2.md = |=20 > > sed 's/"/\\"/g')" \=20 > > -V s3=3D"$( pandoc -t opendocument -f markdown sections/section3.md = |=20 > > sed 's/"/\\"/g')"=20 > > $ sed -i -e 's/\\"/"/g' my.odt.xml=20 > > $ pandoc --template my.odt.xml main.md -o my.odt=20 > > Result: Empty .odt file, but elements in content.xml seem ok??=C2=BF!= =20 > > * Generating a yaml file in order to make pandoc read vars from it,= =20 > > rather than from the command line and avoid.=20 > >=20 > > Result: In progress... I couldn't make pandoc read markdown from yaml= .=20 > > However, I'm in doubt about what main.md is... I'm using a just=20 > touched=20 > > file.=20 > > El martes, 26 de abril de 2016, 23:22:51 (UTC+2), John MacFarlane=20 > > escribi=C3=B3:=20 > >=20 > > There are two things to fiddle with. The --reference-odt,=20 > > which can help with style (spacing, margins, etc.), and=20 > > the opendocument template, which is a place to put hooks=20 > > for content.=20 > > You can create a custom opendocument template (use=20 > > 'pandoc -D opendocument' to get the default one).=20 > > In place of $body$ you might have, for example,=20 > > $s1$, $s2$, and $s3$, perhaps with some content=20 > > intervening.=20 > > You can then use pandoc to fill these variables:=20 > > pandoc --template mycustom.opendocument [1]main.md -o my.odt \=20 > > -V s1=3D$(pandoc -f markdown -t opendocument [2]s1.md)=20 > > -V s2=3D$(pandoc -f markdown -t opendocument [3]s2.md)=20 > > -V s3=3D$(pandoc -f markdown -t opendocument [4]s3.md)=20 > >=20 > > --=20 > > You received this message because you are subscribed to the Google=20 > > Groups "pandoc-discuss" group.=20 > > To unsubscribe from this group and stop receiving emails from it, sen= d=20 > > an email to [5]pandoc-discus...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org .=20 > > To post to this group, send email to=20 > > [6]pandoc-...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org .=20 > > To view this discussion on the web visit=20 > > [7] > https://groups.google.com/d/msgid/pandoc-discuss/59292504-c115-4935-=20 > > b7e2-004c0c875289%40googlegroups.com.=20 > > For more options, visit [8]https://groups.google.com/d/optout.=20 > >=20 > >References=20 > >=20 > > 1. http://main.md/=20 > > 2.=20 > http://www.google.com/url?q=3Dhttp://s1.md&sa=3DD&sntz=3D1&usg=3DAFQjCNFf= Ok5lY6XBrSOLLvz5QcCpy_EH-w=20 > > 3. http://s2.md/=20 > > 4. http://s3.md/=20 > > 5. mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org = =20 > > 6. mailto:pandoc-...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org =20 > > 7.=20 > https://groups.google.com/d/msgid/pandoc-discuss/59292504-c115-4935-b7e2-= 004c0c875289-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org?utm_medium=3Demail&utm_source=3Dfooter=20 > > 8. https://groups.google.com/d/optout=20 > > --=20 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 e= mail 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/a5ea9be7-5547-4124-a71c-f88481a97649%40googlegroups.com. For more options, visit https://groups.google.com/d/optout. ------=_Part_183_677372410.1461920390249 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Yeah! I did it and it's, but formatting fully working.= Thanks!

Now I'm getting some formatting issues, so = I'll open a new thread for it.

Thanks!!
<= div>


El mi=C3=A9rcoles, 27 de abril de 2016, 19:21:35= (UTC+2), John MacFarlane escribi=C3=B3:
Well, you could always use python or something instead of
bash; that would allow you to put arbitrary string values
in as command line arguments without worrying about escapes
and quoting.

+++ JDani Jim=C3=A9nez [Apr 27 16 05:00 ]:
> =C2=A0 This solution is not working... The -V $(pandoc...) command= s output
> =C2=A0 contains characters that are control characters for bash, s= o the
> =C2=A0 command cannot be launched like that.
> =C2=A0 Example:
> =C2=A0 $ pandoc --template odt.template main.md -t opendocument -o my.odt -V
> =C2=A0 s1=3D$( pandoc -t opendocument -f markdown sections/section1.md =C2=A0) -V
> =C2=A0 s2=3D$( pandoc -t opendocument -f markdown sections/section2.md ) -V
> =C2=A0 s3=3D$( pandoc -t opendocument -f markdown sections/section3.md )
> =C2=A0 pandoc: text:style-name=3D"Heading_20_1": op= enFile: does not exist (No
> =C2=A0 such file or directory)
> =C2=A0 The same, but with the debug enabled:
> =C2=A0 $ set -x
> =C2=A0 $ pandoc --template odt.template main.md -t opendocument -o my.odt -V
> =C2=A0 s1=3D$( pandoc -t opendocument -f markdown sections/section1.md =C2=A0) -V
> =C2=A0 s2=3D$( pandoc -t opendocument -f markdown sections/section2.md ) -V
> =C2=A0 s3=3D$( pandoc -t opendocument -f markdown sections/section3.md )
> =C2=A0 ++ pandoc -t opendocument -f markdown sections/section1.md
> =C2=A0 ++ pandoc -t opendocument -f markdown sections/section2.md
> =C2=A0 ++ pandoc -t opendocument -f markdown sections/section3.md
> =C2=A0 + pandoc --template odt.template main.md -t opendocument -o my.odt -V
> =C2=A0 's1=3D<text:h' 'text:style-name=3D"Head= ing_20_1"'
> =C2=A0 'text:outline-level=3D"1">Encabezado&= #39; '1</text:h>' '<text:h'
> =C2=A0 'text:style-name=3D"Heading_20_2"' &= #39;text:outline-level=3D"2">Encabezado'
> =C2=A0 '2</text:h>' '<text:h' 'text:s= tyle-name=3D"Heading_20_3"'
> =C2=A0 'text:outline-level=3D"3">Encabezado&= #39; '3</text:h>' '<text:list'
> =C2=A0 'text:style-name=3D"L1">' '<tex= t:list-item>' '<text:p'
> =C2=A0 'text:style-name=3D"P1">lista' item &#= 39;1</text:p>' '</text:list-item>'
> =C2=A0 '<text:list-item>' '<text:p' '= text:style-name=3D"P1">lista' item
> =C2=A0 '2</text:p>' '</text:list-item>'= ; '<text:list-item>' '<text:p'
> =C2=A0 'text:style-name=3D"P1">lista' item &#= 39;3</text:p>' '</text:list-item>'
> =C2=A0 '</text:list>' -V 's2=3D<text:p' &= #39;text:style-name=3D"Text_20_body">Prueba'
> =C2=A0 de texto en '<text:span' 'text:style-name=3D= "T1">Negrita</text:span>' ,
> =C2=A0 '<text:span' 'text:style-name=3D"T2&quo= t;>cursiva</text:span>,' '<text:span'
> =C2=A0 'text:style-name=3D"T3">tachado</t= ext:span>' y '<text:span'
> =C2=A0 'text:style-name=3D"T4">mezcla</te= xt:span><text:span'
> =C2=A0 'text:style-name=3D"T5">' '</te= xt:span><text:span'
> =C2=A0 'text:style-name=3D"T6">de</text:s= pan><text:span' 'text:style-name=3D"T7">'
> =C2=A0 '</text:span><text:span'
> =C2=A0 'text:style-name=3D"T8">negrita</t= ext:span><text:span'
> =C2=A0 'text:style-name=3D"T9">' '</te= xt:span><text:span'
> =C2=A0 'text:style-name=3D"T10">y</text:s= pan><text:span'
> =C2=A0 'text:style-name=3D"T11">' '</t= ext:span><text:span'
> =C2=A0 'text:style-name=3D"T12">negrita</= text:span><text:span'
> =C2=A0 'text:style-name=3D"T13">' '</t= ext:span><text:span'
> =C2=A0 'text:style-name=3D"T14">cursiva</= text:span></text:p>' -V 's3=3D<text:p'
> =C2=A0 'text:style-name=3D"Text_20_body">Pru= eba' de link: '<text:a'
> =C2=A0 'xlink:type=3D"simple"' 'xlink:href= =3D"ht= tps://www.google.com"'
> =C2=A0 'office:name=3D""><text:span' '= text:style-name=3D"Definition">I'\''m' an
> =C2=A0 inline-style link with 'title</text:span></tex= t:a>' Prueba de imagen:
> =C2=A0 '<draw:frame' 'draw:name=3D"img1"&= gt;<draw:image'
> =C2=A0 'xlink:href=3D"deloitte.jpg"' 'xlink:= type=3D"simple"' 'xlink:show=3D"embed"'
> =C2=A0 'xlink:actuate=3D"onLoad"' '/><= /draw:frame>' Prueba de 'c=C3=B3digo</text:p>'
> =C2=A0 '<text:p' 'text:style-name=3D"P1"&= gt;Prueba' de 'c=C3=B3digo</text:p>'
> =C2=A0 pandoc: text:style-name=3D"Heading_20_1": op= enFile: does not exist (No
> =C2=A0 such file or directory)
> =C2=A0 I tryed these ways to get
> =C2=A0 =C2=A0 * Using quotes and scaping quotes in the output of p= andoc variable
> =C2=A0 =C2=A0 =C2=A0 commands. Like this
>
> =C2=A0 pandoc \
> =C2=A0 =C2=A0--template odt.template \
> =C2=A0 =C2=A0main.md \
> =C2=A0 =C2=A0-o my.odt \
> =C2=A0 =C2=A0-V s1=3D"$( pandoc -t opendocument -f markdown s= ections/section1.md =C2=A0|
> =C2=A0 sed 's/"/\\"/g')" \
> =C2=A0 =C2=A0-V s2=3D"$( pandoc -t opendocument -f markdown s= ections/section2.md =C2=A0|
> =C2=A0 sed 's/"/\\"/g')" \
> =C2=A0 =C2=A0-V s3=3D"$( pandoc -t opendocument -f markdown s= ections/section3.md =C2=A0|
> =C2=A0 sed 's/"/\\"/g')"
> =C2=A0 Result: Malformed odt. Quotes keep scaped in contet.xml
> =C2=A0 =C2=A0 * A three steps procedure
>
> =C2=A0 =C2=A0 * Compose an xml opendocument file, with quotes scap= ed
> =C2=A0 =C2=A0 * Remove backslashes, unscape quotes
> =C2=A0 =C2=A0 * Generate the odt
>
> =C2=A0 $ pandoc \
> =C2=A0 =C2=A0--template odt.template \
> =C2=A0 =C2=A0main.md \
> =C2=A0 =C2=A0-t opendocument \
> =C2=A0 =C2=A0-o my.odt.xml \
> =C2=A0 =C2=A0-V s1=3D"$( pandoc -t opendocument -f markdown s= ections/section1.md =C2=A0|
> =C2=A0 sed 's/"/\\"/g')" \
> =C2=A0 =C2=A0-V s2=3D"$( pandoc -t opendocument -f markdown s= ections/section2.md =C2=A0|
> =C2=A0 sed 's/"/\\"/g')" \
> =C2=A0 =C2=A0-V s3=3D"$( pandoc -t opendocument -f markdown s= ections/section3.md =C2=A0|
> =C2=A0 sed 's/"/\\"/g')"
> =C2=A0 $ sed -i -e 's/\\"/"/g' my.odt.xml
> =C2=A0 $ pandoc --template my.odt.xml m= ain.md -o my.odt
> =C2=A0 Result: Empty .odt file, but elements in content.xml seem o= k??=C2=BF!
> =C2=A0 =C2=A0 * Generating a yaml file in order to make pandoc rea= d vars from it,
> =C2=A0 =C2=A0 =C2=A0 rather than from the command line and avoid.
>
> =C2=A0 Result: In progress... I couldn't make pandoc read mark= down from yaml.
> =C2=A0 However, I'm in doubt about what main.md is... I'm using a just touched
> =C2=A0 file.
> =C2=A0 El martes, 26 de abril de 2016, 23:22:51 (UTC+2), John MacF= arlane
> =C2=A0 escribi=C3=B3:
>
> =C2=A0 =C2=A0 There are two things to fiddle with. =C2=A0The --ref= erence-odt,
> =C2=A0 =C2=A0 which can help with style (spacing, margins, etc.), = and
> =C2=A0 =C2=A0 the opendocument template, which is a place to put h= ooks
> =C2=A0 =C2=A0 for content.
> =C2=A0 =C2=A0 You can create a custom opendocument template (use
> =C2=A0 =C2=A0 'pandoc -D opendocument' to get the default = one).
> =C2=A0 =C2=A0 In place of $body$ you might have, for example,
> =C2=A0 =C2=A0 $s1$, $s2$, and $s3$, perhaps with some content
> =C2=A0 =C2=A0 intervening.
> =C2=A0 =C2=A0 You can then use pandoc to fill these variables:
> =C2=A0 =C2=A0 pandoc --template mycustom.opendocument [1]main.md -o my.odt \
> =C2=A0 =C2=A0 =C2=A0 -V s1=3D$(pandoc -f markdown -t opendocument = [2]s1.md)
> =C2=A0 =C2=A0 =C2=A0 -V s2=3D$(pandoc -f markdown -t opendocument = [3]s2.md)
> =C2=A0 =C2=A0 =C2=A0 -V s3=3D$(pandoc -f markdown -t opendocument = [4]s3.md)
>
> =C2=A0 --
> =C2=A0 You received this message because you are subscribed to the= Google
> =C2=A0 Groups "pandoc-discuss" group.
> =C2=A0 To unsubscribe from this group and stop receiving emails fr= om it, send
> =C2=A0 an email to [5]pandoc-discus...@googlegroups.com.
> =C2=A0 To post to this group, send email to
> =C2=A0 [6]pandoc-...@googlegroups.com.
> =C2=A0 To view this discussion on the web visit
> =C2=A0 [7]http= s://groups.google.com/d/msgid/pandoc-discuss/59292504-c115-4935-<= /a>
> =C2=A0 b7e2-004c0c875289%
40googlegroups.com.
> =C2=A0 For more options, visit [8]https:= //groups.google.com/d/optout.
>
>References
>
> =C2=A0 1. http://main.md/
> =C2=A0 2. http://www.google.com/= url?q=3Dhttp://s1.md&sa=3DD&sntz=3D1&usg=3DAFQjCNFfOk= 5lY6XBrSOLLvz5QcCpy_EH-w
> =C2=A0 3. http://s2.md/
> =C2=A0 4. http://s3.md/
> =C2=A0 5. mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> =C2=A0 6. mailto:pandoc-...@googlegroups.com
> =C2=A0 7. https://groups.google.com/d/msgid/pandoc-discuss/59292504-c= 115-4935-b7e2-004c0c875289@googlegroups.com?utm_medium=3Demail&am= p;utm_source=3Dfooter
> =C2=A0 8. https://groups.google.com/d/optout

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/= msgid/pandoc-discuss/a5ea9be7-5547-4124-a71c-f88481a97649%40googlegroups.co= m.
For more options, visit http= s://groups.google.com/d/optout.
------=_Part_183_677372410.1461920390249-- ------=_Part_182_2101390056.1461920390247--