Description
Bug description
I'm trying to generate an html output with figures generated by python and specify the name of the output file and directory. When I do this, the html is broken and the image files do not link correctly.
For some background I would like to use quarto parameters with python to generate a series of web pages in a sub-directory for my project, which is a website. I'm trying to use the --output
and --output-dir
flags on the cli to specify the name of the output file instead of the template .qmd file that I created.
Steps to reproduce
See the following github repo: https://github.com/anielsen001/quarto-output-dir-files
Run this command:
quarto render demo/demo.qmd --output new_demo.html --output-dir _site/
view the output html in _site/new_demo.html
in a browser.
If you do a simple quarto render
on the entire project, then _site/demo/demo.html
views properly in a browser.
I tried a second alternative:
quarto render demo/demo.qmd --output new_demo.html --output-dir _site/new_demo
This version generates an entire new website at _site/new_demo
and the resulting _site/new_demo/new_demo.html
is also broken.
Expected behavior
I expect to specify the name of an output file and directory for an html page and have the generated figures link correctly to the html page.
Actual behavior
The generated html does not link correctly to the figures and the additional css formatting is missing.
Your environment
editing in emacs, using cli to generate output, chrome to view html output
Quarto check output
Quarto 1.5.57
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.2.0: OK
Dart Sass version 1.70.0: OK
Deno version 1.41.0: OK
Typst version 0.11.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 1.5.57
Path: /opt/quarto/bin
[✓] Checking tools....................OK
TinyTeX: (not installed)
Chromium: (not installed)
[✓] Checking LaTeX....................OK
Using: Installation From Path
Path: /usr/bin
Version: 2019
[✓] Checking basic markdown render....OK
[✓] Checking Python 3 installation....OK
Version: 3.12.1
Path: /home/apn/temp/output-name-test/venv/bin/python3
Jupyter: 5.7.2
Kernels: python3
[✓] Checking Jupyter engine render....OK
[✓] Checking R installation...........(None)
Unable to locate an installed version of R.
Install R from https://cloud.r-project.org/