Here is the reproducible example.
---
author: Jiaxiang Li
date: "`r Sys.Date()`"
output: bookdown::gitbook
---
# test_heading
xxx
I save the code into an Rmd file a20200720144508.Rmd
, when I run rmarkdown::render
, I get the output file named by test_heading.html
instead of the default a20200720144508.html
.
For the reproducible purpose, here is my session infomation.
"si"
#> [1] "si"
Created on 2020-07-20 by the reprex package (v0.3.0)
Session info
devtools::session_info()
#> - Session info ---------------------------------------------------------------
#> setting value
#> version R version 3.6.0 (2019-04-26)
#> os Windows 10 x64
#> system x86_64, mingw32
#> ui RTerm
#> language (EN)
#> collate Chinese (Simplified)_China.936
#> ctype Chinese (Simplified)_China.936
#> tz Asia/Taipei
#> date 2020-07-20
#>
#> - Packages -------------------------------------------------------------------
#> package * version date lib source
#> assertthat 0.2.1 2019-03-21 [2] CRAN (R 3.6.2)
#> backports 1.1.5 2019-10-02 [2] CRAN (R 3.6.1)
#> callr 3.2.0 2019-03-15 [2] CRAN (R 3.6.0)
#> cli 2.0.1 2020-01-08 [2] CRAN (R 3.6.2)
#> crayon 1.3.4 2017-09-16 [2] CRAN (R 3.6.0)
#> desc 1.2.0 2018-05-01 [2] CRAN (R 3.6.0)
#> devtools 2.1.0 2019-07-06 [2] CRAN (R 3.6.1)
#> digest 0.6.19 2019-05-20 [2] CRAN (R 3.6.0)
#> evaluate 0.14 2019-05-28 [2] CRAN (R 3.6.0)
#> fansi 0.4.0 2018-10-05 [2] CRAN (R 3.6.0)
#> fs 1.3.1 2019-05-06 [2] CRAN (R 3.6.0)
#> glue 1.3.1 2019-03-12 [2] CRAN (R 3.6.0)
#> highr 0.8 2019-03-20 [2] CRAN (R 3.6.0)
#> htmltools 0.4.0 2019-10-04 [2] CRAN (R 3.6.1)
#> knitr 1.27 2020-01-16 [2] CRAN (R 3.6.2)
#> magrittr 1.5 2014-11-22 [2] CRAN (R 3.6.1)
#> memoise 1.1.0 2017-04-21 [2] CRAN (R 3.6.1)
#> pkgbuild 1.0.3 2019-03-20 [2] CRAN (R 3.6.1)
#> pkgload 1.0.2 2018-10-29 [2] CRAN (R 3.6.1)
#> prettyunits 1.0.2 2015-07-13 [2] CRAN (R 3.6.0)
#> processx 3.3.1 2019-05-08 [2] CRAN (R 3.6.0)
#> ps 1.3.0 2018-12-21 [2] CRAN (R 3.6.0)
#> R6 2.4.1 2019-11-12 [2] CRAN (R 3.6.2)
#> Rcpp 1.0.4.6 2020-04-09 [2] CRAN (R 3.6.3)
#> remotes 2.1.0 2019-06-24 [2] CRAN (R 3.6.1)
#> rlang 0.4.4 2020-01-28 [2] CRAN (R 3.6.0)
#> rmarkdown 2.3 2020-06-18 [1] CRAN (R 3.6.3)
#> rprojroot 1.3-2 2018-01-03 [2] CRAN (R 3.6.0)
#> sessioninfo 1.1.1 2018-11-05 [2] CRAN (R 3.6.0)
#> stringi 1.4.3 2019-03-12 [2] CRAN (R 3.6.0)
#> stringr 1.4.0 2019-02-10 [2] CRAN (R 3.6.0)
#> testthat 2.3.2 2020-03-02 [2] CRAN (R 3.6.3)
#> usethis 1.5.1.9000 2020-02-04 [2] Github (r-lib/usethis@e7c1f17)
#> withr 2.1.2 2018-03-15 [2] CRAN (R 3.6.0)
#> xfun 0.8 2019-06-25 [2] CRAN (R 3.6.1)
#> yaml 2.2.0 2018-07-25 [2] CRAN (R 3.6.0)
#>
#> [1] C:/Users/lijiaxiang/Documents/R/win-library/3.6
#> [2] C:/Program Files/R/R-3.6.0/library
I am curious whether or it this default setting is OK or it is a bug? For now, I avoid it by deleting the first heading.