Including Temporary Files in Quarto and Deleting afterwards #10077
Answered
by
mcanouil
Jiayou-Chao
asked this question in
Q&A (Q1)
DescriptionI want to generate some intermediate temporary qmd files but delete them afterwards to make my working directory folder clean. ```{r}
generate_qmd(path = "temporary.qmd")
```
{{< include temporary.qmd >}}
```{r}
file.remove("temporary.qmd")
```However, there will be an error message: "could not find file temporary.qmd." To make things even worse, I have to create a Is there a workaround to this? Or should it be a feature request? |
Answered by
mcanouil
Jun 20, 2024
Replies: 2 comments 1 reply
|
Use project scripts: https://quarto.org/docs/projects/scripts.html#pre-and-post-render |
1 reply
Answer selected by
Jiayou-Chao
|
You're confusing execution orders of different parts of the document. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Use project scripts: https://quarto.org/docs/projects/scripts.html#pre-and-post-render