Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Add automated pre-/post-render helper functions#7

Open
wlangera wants to merge 91 commits into
mainfrom
6-proposal-add-automated-quarto-prepost-render-helper-functions
Open

Add automated pre-/post-render helper functions#7
wlangera wants to merge 91 commits into
mainfrom
6-proposal-add-automated-quarto-prepost-render-helper-functions

Conversation

@wlangera
Copy link
Copy Markdown

@wlangera wlangera commented Dec 5, 2025

Metadata

  • update package version
  • update citation files
  • update NEWS
  • checklist checks
  • wait for v0.2.0 to be merged

Functions
autoqmd_generate_children()

  • script
  • input checks
  • documentation
  • examples
  • unit tests
  • improve code coverage

autoqmd_insert_includes() --> autoqmd_insert_children()

  • script
  • input checks
  • documentation
  • examples
  • unit tests
  • improve code coverage

autoqmd_dependency_stamp()

  • script
  • input checks
  • documentation
  • examples
  • unit tests

autoqmd_prepare()

  • script
  • input checks
  • documentation
  • examples
  • unit tests

autoqmd_cleanup()

  • script
  • input checks
  • documentation
  • examples
  • unit tests
  • improve code coverage

autoqmd_finalise()

  • script
  • input checks
  • documentation
  • examples
  • unit tests

Other
Tutorial

  • Review general text
  • Use iris dataset to make chapter per species example
  • Make freeze version of iris example

Consistency

  • Make sure examples and documentation follows good practises of tutorial
  • Make sure examples and documentation are consistent over autoqmd functions
    - .qmd files or QMD or Quarto
    - ...

New tasks (see discussion below)

  • Update vignette
    • remarks Els
    • use better template file name example
    • do not use _qmd_ for freeze names
    • add info about new argument dependency files
    • explain use difference between quarto book and website?
  • simplify autoqmd_dependency_stamp: users should give paths to dependencies themselves
    • rewrite autoqmd_dependency_stamp
    • add argument to autoqmd_dependency_stamp
    • update unit tests of autoqmd_insert_includes
    • add argument to autoqmd_prepare
  • Add warning message at the top of the automatically generated files (child files)
  • Add list of child documents in _quarto.yml #12 (PR Implement child documents for quarto website #13)

@wlangera wlangera self-assigned this Dec 5, 2025
@wlangera wlangera added the enhancement New feature or request label Dec 5, 2025
@wlangera wlangera linked an issue Dec 5, 2025 that may be closed by this pull request
@wlangera
Copy link
Copy Markdown
Author

Thanks for the nice ideas, @ElsLommelen!

For now, would you be willing to create an issue for each of your suggestions? For both, I’d like to think a bit more about the best way to implement them so everything stays consistent and well tested. You can reply to my comments below in the issues to provide any extra details.

I have two more suggestions, up to you to decide on adding them (or not):

  • when using child documents, it could be helpful to cache them, as it may be time consuming to build all of them each time during development while there are no changes. For now I added this in the yml heading of my template qmd, but it may be more convenient to add it as an argument in autoqmd_generate_children()? Otherwise it seems helpful to add it as a suggestion in the vignette.

Could you clarify what you mean by “now I added this in the yml heading”? A quick copy-paste or link would help. I’ll need to think about how this would work and how it differs from the existing freeze argument. If you have concrete ideas, feel free to share them in the issue.

  • for use of child documents in a website, I developed code to replace a specific text in a quarto.yml template with titles for a TOC and references to the corresponding .qmd child documents (see code starting here). It seems to work fine except for the fact that the preview is not running well after rendering due to this reported issue. Would it be an idea to add this as a separate function? Please let me know if you want me to contribute in this.

I agree it cwould be nice to have this as a separate function. I’d also like to think about how it would integrate with the other autoqmd functions in terms of naming and documentation. Also if you have a basic example to use in the unit tests, please let me know.

@wlangera wlangera requested a review from ElsLommelen April 15, 2026 11:30
@wlangera
Copy link
Copy Markdown
Author

@ElsLommelen I have implemented the use of _quarto.yml.
Important: I have changed the name autoqmd_insert_includes() --> autoqmd_insert_children() and the argument qmd_file to target_file.

The vignette is updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Proposal: Add automated Quarto pre/post-render helper functions

3 participants