From 9f57a912a66135681a6698252f7ec5d0e70fd67e Mon Sep 17 00:00:00 2001 From: Matthew Brett Date: Thu, 14 Nov 2024 20:53:23 +0000 Subject: [PATCH] Fixes to template changes Make language selection more explicit. No longer rely on the notebook extension to tell us the language. --- source/_common.R | 2 +- source/_quarto.yml.template | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/_common.R b/source/_common.R index 3f41b2a4..744849d8 100644 --- a/source/_common.R +++ b/source/_common.R @@ -26,7 +26,7 @@ knitr::opts_chunk$set( options(dplyr.print_min = 6, dplyr.print_max = 6) # Book edition from notebook format in build spec -is_py_ed <- ._spec$noteout$`nb-format` == 'ipynb' +is_py_ed <- ._spec$processing$language == 'python' is_r_ed <- !is_py_ed knitr::opts_template$set(svg_fig = list(eval=TRUE, echo=FALSE, diff --git a/source/_quarto.yml.template b/source/_quarto.yml.template index 29b2dee6..2e30df14 100644 --- a/source/_quarto.yml.template +++ b/source/_quarto.yml.template @@ -96,7 +96,7 @@ noteout: pre-filter: ['todo', 'comment'] filter-divspans: {filter_divspans} nb-flatten-divspans: {nb_flatten_divspans} - nb-format: Rmd + nb-format: {nb_format} nb-strip-header-nos: false interact-url: "/{interact-sdir}/lab/index.html?path=" url-root: {url-root}