diff --git a/NEWS.md b/NEWS.md index 7141a326..1c67bfb3 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,5 +1,7 @@ # CHANGES IN blogdown VERSION 1.14 +- For R Markdown posts, the default rendering method has been changed from `html` to `markdown`. If `options('blogdown.method')` is not set, it will be set to `'markdown'`. This option will also be set in `.Rprofile` for newly created sites via `blogdown::new_site()`. Users who have already set this `blogdown.method` option will not be affected. The motivation for this change is that `markdown` output often works better with Hugo themes and is less surprising, even though the `html` method allows for richer Markdown features because of Pandoc (thanks, @SebPouliot #737, @austinwpearce #591). + - When rendering Rmd posts that involve time-consuming and intensive computing while serving the site, the `hugo` process can die (for unknown reasons). Now the `hugo` process will be suspended before rendering Rmd posts, and resumed after the rendering is done. Hopefully this will keep the server process alive (thanks, @XiangyunHuang, https://d.cosx.org/d/423509). # CHANGES IN blogdown VERSION 1.13 diff --git a/R/render.R b/R/render.R index 2845f27c..fe72ef0b 100644 --- a/R/render.R +++ b/R/render.R @@ -90,7 +90,7 @@ build_site = function(local = FALSE, run_hugo = TRUE, build_rmd = FALSE, ...) { } build_method = function() { - methods = c('html', 'markdown', 'custom') + methods = c('markdown', 'html', 'custom') match.arg(get_option('blogdown.method', methods), methods) } diff --git a/inst/resources/Rprofile b/inst/resources/Rprofile index a255290f..84c7d72f 100644 --- a/inst/resources/Rprofile +++ b/inst/resources/Rprofile @@ -15,6 +15,6 @@ options( blogdown.serve_site.startup = FALSE, # to disable knitting Rmd files on save, set this option to FALSE blogdown.knit.on_save = TRUE, - # build .Rmd to .html (via Pandoc); to build to Markdown, set this option to 'markdown' - blogdown.method = 'html' + # build .Rmd to .md; to build to .html (via Pandoc), set this option to 'html' + blogdown.method = 'markdown' )