Open gadenbuie opened 1 month ago
You mean revealjs-url
? not remarkjs-url
? (Remark.js is not supported)
You mean
revealjs-url
? notremarkjs-url
? (Remark.js is not supported)
Yeah and apparently I remembered the right one somewhere around halfway through writing up the issue.
For context on this one, my understanding is that we are copying the folder and then passing the final path as value directly to Pandoc's own variable for this https://pandoc.org/MANUAL.html#variables-for-html-slides
then it is used in HTML template as is https://github.com/quarto-dev/quarto-cli/blob/814604696f1a36c4351245100f72c7fb75fba5eb/src/resources/formats/revealjs/pandoc/revealjs.template#L19-L20
The problem here happens for the copy of the provided folder. Here is the stack trace
Stack trace:
at wrapErrorWithPath (file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/vendor/deno.land/std@0.217.0/fs/walk.ts:50:10)
at walkSync (file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/vendor/deno.land/std@0.217.0/fs/walk.ts:219:11)
at walkSync.next (<anonymous>)
at copyMinimal (file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/core/copy.ts:70:11)
at file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/format/reveal/format-reveal-theme.ts:98:5
at Array.forEach (<anonymous>)
at revealTheme (file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/format/reveal/format-reveal-theme.ts:97:22)
at Object.formatExtras (file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/format/reveal/format-reveal.ts:153:29)
at runPandoc (file:///C:/Users/chris/Documents/DEV_R/quarto-cli/src/command/render/pandoc.ts:393:31)
at eventLoopTick (ext:core/01_core.js:153:7)
I guess in project context, it was designed to use a folder at project root to use for all presentation. Or it may not even work at all for a project setting
Possibly, just using absolute path before doing the copy could solve this.
Bug description
When
revealjs-url
is used, the path is not relative to the document in which the key appears, but rather the working directory wherequarto render
orquarto preview
are called. I believe the path torevealjs-url
should be relative to the source document and should be resolved as part of the metadata resolution.Steps to reproduce
Note the relative path in
revealjs-url
. Callingquarto render slide.qmd
from insideslides/
works, but if you move up one directory, the website fails to render.If you make
revealjs-url
relative to the website root, it will work for a bit. But if you happen to have your website inside a folder in your repo, e.g.website/
, thenquarto render website
will fail (this is effectively what's called by thequarto-actions/publish
action).Expected behavior
revealjs-url
should be relative to the place where it's defined, and should not change whenquarto render
is called from a different directory.Actual behavior
quarto render
works from some directories and fails from others.Your environment
Default quarto-actions/publish action (same version of quarto as reported below). Also locally on MacOS 14.5
Quarto check output