From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/32228 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Julien Dutant Newsgroups: gmane.text.pandoc Subject: Re: Simplified Markdown with no HTML tags Date: Thu, 23 Feb 2023 06:47:00 -0800 (PST) Message-ID: <7bc05dcb-7a1a-49fd-9467-dbec7a135720n@googlegroups.com> References: <71a7bdeb-b8a7-461c-b70b-7452bb067f02n@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_1428_329624825.1677163620416" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7737"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBC5Y3356IYIOL6G5T4DBUBH2TZ674-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Thu Feb 23 15:47:04 2023 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-qt1-f184.google.com ([209.85.160.184]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1pVCsC-0001sh-JS for gtp-pandoc-discuss@m.gmane-mx.org; Thu, 23 Feb 2023 15:47:04 +0100 Original-Received: by mail-qt1-f184.google.com with SMTP id t5-20020ac865c5000000b003abcad051d2sf5062432qto.12 for ; Thu, 23 Feb 2023 06:47:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20210112; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :sender:from:to:cc:subject:date:message-id:reply-to; bh=xeuRP8y1RAHo0TadXkTmr3fBPqhRDNj2F0BN0eeU/hA=; b=ScXvjztZ+2sVVhqwv32/doqSFTXZlihjy1bLMEcF55ZS35LAXHv4vx7cj7cplTKBBK jLo548naxtPhZgvSL8SwG7isFiGLb6NOVr8D731kQbRzwE9CxkmYCensWMrdm4Lzow8o ja3VkyuI8wH6ym87J3DnuKTT+ktDSgYTv8LAg4QuSo8X6M6awu8cBdbXGT8pgwcZO97n 1mBRiXaxRqCrxJ03ol1w5fNDu+yLdNDwVhjCXGsANzKk7/tT2hq+tndseySHidS2JFfR CYb2YpexPuOeBFdbFNMjUSWiuy2Y6+V6TuQ0E+YNFn3tvaDc1iGQDYECsDonE5Ug9AZQ EAYw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=xeuRP8y1RAHo0TadXkTmr3fBPqhRDNj2F0BN0eeU/hA=; b=cS+98GH/adEvPS6vYtbN3XBnsdIumvNeVkjg40OTKn9jTZtJ/7NnFvIaUEXJurBYaV r0HIlO9vd60JDE+fS8rEElegFsMbUnhghCAGvm8aFfigopdmukFXp4Orn9LYOvtPkFRW z6jQpCuOU2p/SY7/1ln10L8OlvEz4axsZQiyu5biFCkb7Unygfjfafvhnix4aQkJjyIu S0JeEqyecmOwkOa57VBisGB6OmhbbK6ZwgTbDIcRte3xi9NTdueSiwK+GEelBITv95Pg 9X+P9i9tdiA+cd5LFJHI63wLV55uNx7mkWF1M72740rQ8KGx6qlukHuONLupdYYIAB+7 28uw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-sender:mime-version:subject:references:in-reply-to :message-id:to:from:date:x-gm-message-state:sender:from:to:cc :subject:date:message-id:reply-to; bh=xeuRP8y1RAHo0TadXkTmr3fBPqhRDNj2F0BN0eeU/hA=; b=ZnLi+/GZfgGJd0m4z5X6RoEB1HXAFQlMK2lcQwUFthSOKfuC9yKejPMgr5bfyZdfeQ dlrzDYmicNxWErT3psI5fP0ft9deL6Sxein3acIPVClefPgxJLp0DIQiJr4aGicqtNwP Ac8yfwg8maAkn4I20lNWy4T6lsA16nkGeAuW74L2kAK11vU333F5OENQ+Ox6nORVQYLe K3eByefkLR04TtwOzi0sscJqO4NLdznvz3gk9G3fjCSWyE0b7bxussJs9MqiZEvh1Pnc tNpdWG/OSlOlEok+NvXtASAV9FY+gFEVYqlj3ZLOtrpnR021wDvS4y1qt7SJFdG2/4+6 lu1w== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AO0yUKVSfbAy0B9V4hCIlx7fc3XzkIXP9aANsOGnf4fr00FKCb3XkTnb nVBwHDQX8YA/eYbWu4sFbG0= X-Google-Smtp-Source: AK7set/RyBR2SdNE5qaXhYYbSzdhJdDxKBpE5olJYuLIPbnBD+wjoi7WqXq3QewUvJ2NvbyI5mDXPg== X-Received: by 2002:a05:620a:2092:b0:733:4e2d:7834 with SMTP id e18-20020a05620a209200b007334e2d7834mr1901981qka.4.1677163623462; Thu, 23 Feb 2023 06:47:03 -0800 (PST) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:622a:2281:b0:3bc:edc5:2588 with SMTP id ay1-20020a05622a228100b003bcedc52588ls9753831qtb.6.-pod-prod-gmail; Thu, 23 Feb 2023 06:47:01 -0800 (PST) X-Received: by 2002:a05:622a:5c8d:b0:3ba:1506:f2 with SMTP id ge13-20020a05622a5c8d00b003ba150600f2mr2866302qtb.2.1677163620902; Thu, 23 Feb 2023 06:47:00 -0800 (PST) In-Reply-To: <71a7bdeb-b8a7-461c-b70b-7452bb067f02n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> X-Original-Sender: julien.dutant-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-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:32228 Archived-At: ------=_Part_1428_329624825.1677163620416 Content-Type: multipart/alternative; boundary="----=_Part_1429_1927952296.1677163620416" ------=_Part_1429_1927952296.1677163620416 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable One way to think about it: it's not about input / output but about format.= =20 HTML has
and in its definition, that's not optional; Pandoc's= =20 internal representation (AST) has Div and Span elements, that's not=20 optional. But whether markdown includes Div / Span syntax ('native_divs'=20 and 'native_spans') is optional, hence the option is on the markdown=20 format, not on the html format.=20 For example if you were writing *to* markdown you could remove Div and=20 Spans with pandoc -t markdown-native_divs-native_spans J On Thursday, February 23, 2023 at 7:05:36=E2=80=AFAM UTC Brian Granger wrot= e: > Looks like asking the question was enough for me to see it in a new light= .=20 > My mistake was applying the extension to the output format rather than th= e=20 > input format. Thus, the following works: > > pandoc -f html-native_divs-native_spans -t markdown > > But this doesn't: > > pandoc -f html -t markdown-native_divs-native_spans > > I don't understand how to think about when to apply extension to the inpu= t=20 > versus the output format, but I do have a solution that enables me to mov= e=20 > forward. > > Cheers, > > Brian > > > > On Wednesday, February 22, 2023 at 10:53:22 PM UTC-8 Brian Granger wrote: > >> Hi all, >> >> I am working on a usage case where I want to generate simplified, clean= =20 >> Markdown without any explicit HTML tags or extended syntax such as the= =20 >> fenced divs syntax (:::::). I only need to preserve the basic content of= =20 >> the HMTL such as section headers, paragraphs, links, code blocks, etc. a= nd=20 >> don't need (or want) any of extra content that would be put into HTML ta= gs.=20 >> I have played with different Markdown format in Pandoc, filters, and=20 >> existing extensions, but haven't been able to achieve this yet. Does any= one=20 >> have any ideas or tips of things to try? >> >> Thank you! >> >> Cheers, >> >> Brian >> > --=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 view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/7bc05dcb-7a1a-49fd-9467-dbec7a135720n%40googlegroups.com. ------=_Part_1429_1927952296.1677163620416 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable One way to think about it: it's not about input / output but about format. = HTML has <div> and <span> in its definition, that's not optiona= l; Pandoc's internal representation (AST) has Div and Span elements, that's= not optional. But whether markdown includes Div / Span syntax ('native_div= s' and 'native_spans') is optional, hence the option is on the markdown for= mat, not on the html format.

For example if you= were writing *to* markdown you could remove Div and Spans with pandoc=C2= =A0 -t markdown-native_divs-native_spans

J
=

On Thursday, February 23, 2023 at 7:05:36=E2=80=AFAM UTC Br= ian Granger wrote:
Looks like asking the question was enough for me to see it in a = new light. My mistake was applying the extension to the output format rathe= r than the input format. Thus, the following works:

pandoc -f html-native_divs-native_spans -t markdown

But thi= s doesn't:

=
pandoc -f html -t markdown-native_= divs-native_spans

I don't understand how= to think about when to apply extension to the input versus the output form= at, but I do have a solution that enables me to move forward.=
=
= Cheers,

Brian

<= /div>


On Wednesday, February 22, 2023 at= 10:53:22 PM UTC-8 Brian Granger wrote:
Hi all,

I am working on a u= sage case where I want to generate simplified, clean Markdown without any e= xplicit HTML tags or extended syntax such as the fenced divs syntax (= :::::). I only need to preserve the basic content of th= e HMTL such as section headers, paragraphs, links, code blocks, etc. and do= n't need (or want) any of extra content that would be put into HTML tag= s. I have played with different Markdown format in Pandoc, filters, and exi= sting extensions, but haven't been able to achieve this yet. Does anyon= e have any ideas or tips of things to try?

Tha= nk you!

Cheers,

Brian
=

--
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 view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/7bc05dcb-7a1a-49fd-9467-dbec7a135720n%40googlegroups.= com.
------=_Part_1429_1927952296.1677163620416-- ------=_Part_1428_329624825.1677163620416--