crowdagger / crowbook

Converts books written in Markdown to HTML, LaTeX/PDF and EPUB

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

File resolution issues when importing + defining base_path

crowdagger opened this issue · comments

Let's say you have the following structure:

  • common.book
  • images/
    • foo.png
  • 01/
    • 01.book
  • 02/
    • 02.book

In common.book, you want to define the base path for images to images/:

resources.base_path.images: images/

You also want to specify an icon for html rendering:

html.icon: foo.png

But now, when you run crowbook 01/01.book you get an error: "Could not find file '01/../images/../foo.png'"

This is because "../" is concatenated to html.icon, which would be the thing to do if resources.base_bath was not defined, but in this case it causes a problem.