If you want to adress only footnotes with one paragraph: function Note(note) if #note.content == 1 then note.content[1].content[1].text = "%%opening%%" .. note.content[1].content[1].text note.content[1].content[#note.content[1].content].text = note.content[1].content[#note.content[1].content].text .. "%%closing%%" return note.content[1].content end return note end Le mercredi 19 juillet 2023 à 15:36:10 UTC+2, Christophe Demko a écrit : > You can use a lua filter: > > $ pandoc --lua-filter note.lua -t markdown | sed -e 's/%%opening%%/\^\[/g' > | sed -e 's/%%closing%%/\]/g' > > with this note.lua file > > function Note(note) > note.content[1].content[1].text = "%%opening%%" .. > note.content[1].content[1].text > note.content[1].content[#note.content[1].content].text = > note.content[1].content[#note.content[1].content].text .. "%%closing%%" > return note.content[1].content > end > Le dimanche 16 juillet 2023 à 17:35:38 UTC+2, tri...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org a écrit : > >> Is it possible to use Pandoc to convert an md file that has reference >> footnotes to one that has inline footnotes - just by going from md -> md, >> but failing that via another format. >> >> I have a file containing reference footnotes like this >> ---- >> Example[^1] line of text. >> >> [^1]: Example footnote >> ---- >> >> I would like to convert them all to inline footnotes like this >> >> ---- >> Example^[Example footnote] line of text. >> ---- >> >> Thank you for any help >> >> 'ö-Dzin >> > -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/b680c4f7-0c33-4a3c-9607-1d0fad225ab8n%40googlegroups.com.