public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* Help: Resurively include MD files from links
@ 2021-07-09  3:59 Arran Ubels
       [not found] ` <c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 4+ messages in thread
From: Arran Ubels @ 2021-07-09  3:59 UTC (permalink / raw)
  To: pandoc-discuss


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

Hey,

I attempted to create a lua script for this.. However I wasn't able to 
figure it out. (From a fairly primative base sorry..)

I am trying to make this work:
https://github.com/aubelsb2/pandoc-md-recurse

But using a lua script to pick up the links, append the md file, substitute 
them with references to the new section, and insert images from a relative 
location to the file.

-- 
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/c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n%40googlegroups.com.

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

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

* Re: Help: Resurively include MD files from links
       [not found] ` <c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2021-07-10  9:40   ` Bastien DUMONT
  2021-07-15  1:08     ` Arran Ubels
  0 siblings, 1 reply; 4+ messages in thread
From: Bastien DUMONT @ 2021-07-10  9:40 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

Hi,

What can't you achieve by simply passing a list of files to the command line like this?

pandoc -o test.pdf introduction.md firstchapter/1.md firstchapter/2.md secondchapter/1.md

Le Thursday 08 July 2021 à 08:59:06PM, Arran Ubels a écrit :
> Hey,
> 
> I attempted to create a lua script for this.. However I wasn't able to
> figure it out. (From a fairly primative base sorry..)
> 
> I am trying to make this work:
> 
> https://github.com/aubelsb2/pandoc-md-recurse
> 
> But using a lua script to pick up the links, append the md file,
> substitute them with references to the new section, and insert images
> from a relative location to the file.
> 
> --
> 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 (mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org).
> To view this discussion on the web visit
> (https://groups.google.com/d/msgid/pandoc-discuss/c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n%40googlegroups.com?utm_medium=email&utm_source=footer).

-- 
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/YOlrCbxx/4Xz8FCw%40localhost.


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

* Re: Help: Resurively include MD files from links
  2021-07-10  9:40   ` Bastien DUMONT
@ 2021-07-15  1:08     ` Arran Ubels
       [not found]       ` <CALpzYsANnAz1=YrN4Z+8k2cZiQ3TBZc1FURUHOsy1LZFvYfFGA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 4+ messages in thread
From: Arran Ubels @ 2021-07-15  1:08 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

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

Hi,

1. Relative path of images and other links in document don't work, if I for
instance run: pandoc -o test.pdf introduction.md firstchapter/1.md
firstchapter/2.md secondchapter/1.md and in secondchapter/1.md it refers to
an image in secondchapter it would so as [alt text](img.png) but pandoc
expects it to be: [alt text](secondchapter/img.png) as it expects content
to be relative to the working directory not the referring document
2. Doesn't update references to internal links between documents
3. When you use something like find to generate it (as this is a large
multi md document) it's hard to control ordering with something like find
and produces more overhead when adding new leaflets.

On Sat, 10 Jul 2021 at 19:41, Bastien DUMONT <bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org>
wrote:

> Hi,
>
> What can't you achieve by simply passing a list of files to the command
> line like this?
>
> pandoc -o test.pdf introduction.md firstchapter/1.md firstchapter/2.md
> secondchapter/1.md
>
> Le Thursday 08 July 2021 à 08:59:06PM, Arran Ubels a écrit :
> > Hey,
> >
> > I attempted to create a lua script for this.. However I wasn't able to
> > figure it out. (From a fairly primative base sorry..)
> >
> > I am trying to make this work:
> >
> > https://github.com/aubelsb2/pandoc-md-recurse
> >
> > But using a lua script to pick up the links, append the md file,
> > substitute them with references to the new section, and insert images
> > from a relative location to the file.
> >
> > --
> > 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 (mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org).
> > To view this discussion on the web visit
> > (
> https://groups.google.com/d/msgid/pandoc-discuss/c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n%40googlegroups.com?utm_medium=email&utm_source=footer
> ).
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "pandoc-discuss" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/pandoc-discuss/dEC8YMw3lpE/unsubscribe.
> To unsubscribe from this group and all its topics, 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/YOlrCbxx/4Xz8FCw%40localhost
> .
>

-- 
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/CALpzYsANnAz1%3DYrN4Z%2B8k2cZiQ3TBZc1FURUHOsy1LZFvYfFGA%40mail.gmail.com.

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

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

* Re: Help: Resurively include MD files from links
       [not found]       ` <CALpzYsANnAz1=YrN4Z+8k2cZiQ3TBZc1FURUHOsy1LZFvYfFGA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2021-07-15  8:40         ` John Gabriele
  0 siblings, 0 replies; 4+ messages in thread
From: John Gabriele @ 2021-07-15  8:40 UTC (permalink / raw)
  To: 'Oliver Demetz' via pandoc-discuss

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

What I've done in the past is written a script to process every .txt|md file (with pandoc) in the current directory, and then descend into subdirectories and do likewise. One file being processed at a time, with the cwd right in that file's directory. However, this of course creates a single html page for each file.

I don't know what you mean by, "recursively include md files from links" though. So maybe you're trying to do something else.




On Wed, Jul 14, 2021, at 9:08 PM, Arran Ubels wrote:
> Hi,
> 
> 1. Relative path of images and other links in document don't work, if I for instance run: pandoc -o test.pdf introduction.md firstchapter/1.md firstchapter/2.md secondchapter/1.md and in secondchapter/1.md it refers to an image in secondchapter it would so as [alt text](img.png) but pandoc expects it to be: [alt text](secondchapter/img.png) as it expects content to be relative to the working directory not the referring document
> 2. Doesn't update references to internal links between documents
> 3. When you use something like find to generate it (as this is a large multi md document) it's hard to control ordering with something like find and produces more overhead when adding new leaflets.
> 
> On Sat, 10 Jul 2021 at 19:41, Bastien DUMONT <bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org> wrote:
>> Hi,
>> 
>> What can't you achieve by simply passing a list of files to the command line like this?
>> 
>> pandoc -o test.pdf introduction.md firstchapter/1.md firstchapter/2.md secondchapter/1.md
>> 
>> Le Thursday 08 July 2021 à 08:59:06PM, Arran Ubels a écrit :
>> > Hey,
>> > 
>> > I attempted to create a lua script for this.. However I wasn't able to
>> > figure it out. (From a fairly primative base sorry..)
>> > 
>> > I am trying to make this work:
>> > 
>> > https://github.com/aubelsb2/pandoc-md-recurse
>> > 
>> > But using a lua script to pick up the links, append the md file,
>> > substitute them with references to the new section, and insert images
>> > from a relative location to the file.
>> > 
>> > --
>> > 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 (mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org <mailto:pandoc-discuss%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>).
>> > To view this discussion on the web visit
>> > (https://groups.google.com/d/msgid/pandoc-discuss/c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n%40googlegroups.com?utm_medium=email&utm_source=footer).
>> 
>> -- 
>> You received this message because you are subscribed to a topic in the Google Groups "pandoc-discuss" group.
>> To unsubscribe from this topic, visit https://groups.google.com/d/topic/pandoc-discuss/dEC8YMw3lpE/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org <mailto:pandoc-discuss%2Bunsubscribe@googlegroups.com>.
>> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/YOlrCbxx/4Xz8FCw%40localhost.
> 
> 
> -- 
> 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/CALpzYsANnAz1%3DYrN4Z%2B8k2cZiQ3TBZc1FURUHOsy1LZFvYfFGA%40mail.gmail.com <https://groups.google.com/d/msgid/pandoc-discuss/CALpzYsANnAz1%3DYrN4Z%2B8k2cZiQ3TBZc1FURUHOsy1LZFvYfFGA%40mail.gmail.com?utm_medium=email&utm_source=footer>.

-- 
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/63772906-3131-4e16-8f47-f090e41ee893%40www.fastmail.com.

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

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

end of thread, other threads:[~2021-07-15  8:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-09  3:59 Help: Resurively include MD files from links Arran Ubels
     [not found] ` <c0ecb03f-64c2-4c0e-8b0c-56ed1f380ac5n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2021-07-10  9:40   ` Bastien DUMONT
2021-07-15  1:08     ` Arran Ubels
     [not found]       ` <CALpzYsANnAz1=YrN4Z+8k2cZiQ3TBZc1FURUHOsy1LZFvYfFGA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2021-07-15  8:40         ` John Gabriele

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