Skip to content

Commit a70fa6c

Browse files
committed
Merge branch 'jg-devel'
* jg-devel: (35 commits) Use latest Pandoc in GHA and update workflow (rstudio#2244) Add class to book cover to size using CSS fix the syntax highlighting of |> in LaTeX/PDF output: rstudio/bookdown#1157 (rstudio#2228) Add an option to opt-out the header-attrs HTML dependency in `html_document_base()` (rstudio#2227) Clean up NEWS.md. Updated autogenerated documentation. Fixed conflicts with rstudio main version. Update documentation for html_document. Add self (JG) as a contributor in DESCRIPTION. Resolve conflicts with new updates to RStudio main branch. Clean up a few things from the merge. Fix problem building with GitHub Actions because of `mathjax: local` in the testthat tests. Revert unnecessary formatting change to code in render.R. Revert an unnecessary formatting change to comments in render.R. Update NEWS.md. revert inadevertent change from accidental merge with jg-tree-fix. Removed unnecessary references to `allow_uptree_lib_dir` in `ioslides_presentation` and `slidy_presentation`. Prepare for PR to RStudio. Updated documentation for new parameter in output_format(). Removed packages.bib from tests/testthat. ...
2 parents 81d52ec + 1a2f70a commit a70fa6c

29 files changed

+509
-155
lines changed

.Rbuildignore

+2
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
^tests/testthat/site/_site/
88
^tests/testthat/site/lib/
99
^tests/testthat/site/.*_files/
10+
^tests/testthat/html-uptree-lib_dir/.*\.html$
11+
^tests/testthat/html-uptree-lib_dir/.*\.gitkeep$
1012
^tests/manual/
1113
^\.github$
1214
^pkgdown$

.github/workflows/R-CMD-check.yaml

+17-50
Original file line numberDiff line numberDiff line change
@@ -28,32 +28,33 @@ jobs:
2828
matrix:
2929
config:
3030
# testing R release with last shipped pandoc version in RStudio IDE and new pandoc
31-
# TODO: issue on windows with pandoc 2.11.4 - change when fixed
32-
- {os: windows-latest, pandoc: '2.7.3', r: 'release'}
33-
- {os: macOS-latest, pandoc: '2.11.4', r: 'release'}
34-
- {os: ubuntu-18.04, pandoc: '2.11.4', r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
35-
- {os: ubuntu-18.04, pandoc: 'devel', r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
31+
- {os: windows-latest, pandoc: '2.16.1', r: 'release'}
32+
- {os: macOS-latest, pandoc: '2.16.1', r: 'release'}
33+
- {os: ubuntu-18.04, pandoc: '2.16.1', r: 'release'}
34+
- {os: ubuntu-18.04, pandoc: 'devel', r: 'release'}
3635
# testing older pandoc versions
37-
- {os: ubuntu-18.04, pandoc: '2.7.3', r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
38-
- {os: ubuntu-18.04, pandoc: '2.5', r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
39-
- {os: ubuntu-18.04, pandoc: '2.0.0.1', r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
36+
- {os: ubuntu-18.04, pandoc: '2.14.2', r: 'release'}
37+
- {os: ubuntu-18.04, pandoc: '2.11.4', r: 'release'}
38+
- {os: ubuntu-18.04, pandoc: '2.7.3', r: 'release'}
39+
- {os: ubuntu-18.04, pandoc: '2.5', r: 'release'}
40+
- {os: ubuntu-18.04, pandoc: '2.0.0.1', r: 'release'}
4041
# testing other R versions
41-
- {os: ubuntu-18.04, pandoc: '2.11.4', r: 'oldrel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
42-
- {os: ubuntu-18.04, pandoc: '2.11.4', r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest", http-user-agent: "R/4.0.0 (ubuntu-18.04) R (4.0.0 x86_64-pc-linux-gnu x86_64 linux-gnu) on GitHub Actions" }
42+
- {os: ubuntu-18.04, pandoc: '2.11.4', r: 'oldrel'}
43+
- {os: ubuntu-18.04, pandoc: '2.11.4', r: 'devel', http-user-agent: 'release'}
4344

4445
env:
4546
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
46-
RSPM: ${{ matrix.config.rspm }}
4747
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
48+
R_KEEP_PKG_SOURCE: yes
4849

4950
steps:
5051
- uses: actions/checkout@v2
5152

5253
- uses: r-lib/actions/setup-r@v1
53-
id: install-r
5454
with:
5555
r-version: ${{ matrix.config.r }}
5656
http-user-agent: ${{ matrix.config.http-user-agent }}
57+
use-public-rspm: true
5758

5859
- name: change temp dir
5960
if: runner.os == 'Windows'
@@ -79,52 +80,18 @@ jobs:
7980
cat(readLines("~/.Rprofile"), sep = "\n")
8081
shell: Rscript {0}
8182

82-
- name: Install pak and query dependencies
83-
run: |
84-
install.packages("pak", repos = "https://r-lib.github.io/p/pak/dev/")
85-
saveRDS(pak::pkg_deps("local::.", dependencies = TRUE), ".github/r-depends.rds")
86-
shell: Rscript {0}
87-
88-
- name: Restore R package cache
89-
uses: actions/cache@v2
83+
- uses: r-lib/actions/setup-r-dependencies@v1
9084
with:
91-
path: |
92-
${{ env.R_LIBS_USER }}/*
93-
!${{ env.R_LIBS_USER }}/pak
94-
key: ${{ matrix.config.os }}-${{ steps.install-r.outputs.installed-r-version }}-1-${{ hashFiles('.github/r-depends.rds') }}
95-
restore-keys: ${{ matrix.config.os }}-${{ steps.install-r.outputs.installed-r-version }}-1-
96-
97-
- name: Install system dependencies
98-
if: runner.os == 'Linux'
99-
run: |
100-
pak::local_system_requirements(execute = TRUE)
101-
pak::pkg_system_requirements("rcmdcheck", execute = TRUE)
102-
shell: Rscript {0}
85+
extra-packages: rcmdcheck
10386

104-
- name: Install dependencies
87+
- name: Pandoc and Tinytex info
10588
run: |
106-
pak::local_install_dev_deps(upgrade = TRUE)
107-
pak::pkg_install("rcmdcheck")
108-
shell: Rscript {0}
109-
110-
- name: Session info
111-
run: |
112-
options(width = 100)
113-
pkgs <- .packages(TRUE)
114-
sessioninfo::session_info(pkgs, include_base = TRUE)
11589
rmarkdown::find_pandoc()
11690
tinytex::tlmgr("--version")
11791
tinytex::tl_pkgs()
11892
shell: Rscript {0}
11993

120-
- name: Check
121-
env:
122-
_R_CHECK_CRAN_INCOMING_: false
123-
_R_CHECK_TESTS_NLINES_: 0
124-
run: |
125-
options(crayon.enabled = TRUE)
126-
rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
127-
shell: Rscript {0}
94+
- uses: r-lib/actions/check-r-package@v1
12895

12996
- name: Show testthat output
13097
if: always()

.github/workflows/check-pandoc-daily.yaml

+8-41
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,19 @@ jobs:
1818
config:
1919
- {os: windows-latest}
2020
- {os: macOS-latest}
21-
- {os: ubuntu-18.04, rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
21+
- {os: ubuntu-18.04}
2222

2323
env:
2424
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
25-
RSPM: ${{ matrix.config.rspm }}
2625
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
26+
R_KEEP_PKG_SOURCE: yes
2727

2828
steps:
2929
- uses: actions/checkout@v2
3030

3131
- uses: r-lib/actions/setup-r@v1
32-
id: install-r
32+
with:
33+
use-public-rspm: true
3334

3435
- name: change temp dir
3536
if: runner.os == 'Windows'
@@ -50,52 +51,18 @@ jobs:
5051
cat(readLines("~/.Rprofile"), sep = "\n")
5152
shell: Rscript {0}
5253

53-
- name: Install pak and query dependencies
54-
run: |
55-
install.packages("pak", repos = "https://r-lib.github.io/p/pak/dev/")
56-
saveRDS(pak::pkg_deps("local::.", dependencies = TRUE), ".github/r-depends.rds")
57-
shell: Rscript {0}
58-
59-
- name: Restore R package cache
60-
uses: actions/cache@v2
54+
- uses: r-lib/actions/setup-r-dependencies@v1
6155
with:
62-
path: |
63-
${{ env.R_LIBS_USER }}/*
64-
!${{ env.R_LIBS_USER }}/pak
65-
key: ${{ matrix.config.os }}-${{ steps.install-r.outputs.installed-r-version }}-1-${{ hashFiles('.github/r-depends.rds') }}
66-
restore-keys: ${{ matrix.config.os }}-${{ steps.install-r.outputs.installed-r-version }}-1-
67-
68-
- name: Install system dependencies
69-
if: runner.os == 'Linux'
70-
run: |
71-
pak::local_system_requirements(execute = TRUE)
72-
pak::pkg_system_requirements("rcmdcheck", execute = TRUE)
73-
shell: Rscript {0}
56+
extra-packages: rcmdcheck
7457

75-
- name: Install dependencies
58+
- name: Pandoc and Tinytex info
7659
run: |
77-
pak::local_install_dev_deps(upgrade = TRUE)
78-
pak::pkg_install("rcmdcheck")
79-
shell: Rscript {0}
80-
81-
- name: Session info
82-
run: |
83-
options(width = 100)
84-
pkgs <- .packages(TRUE)
85-
sessioninfo::session_info(pkgs, include_base = TRUE)
8660
rmarkdown::find_pandoc()
8761
tinytex::tlmgr("--version")
8862
tinytex::tl_pkgs()
8963
shell: Rscript {0}
9064

91-
- name: Check
92-
env:
93-
_R_CHECK_CRAN_INCOMING_: false
94-
_R_CHECK_TESTS_NLINES_: 0
95-
run: |
96-
options(crayon.enabled = TRUE)
97-
rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
98-
shell: Rscript {0}
65+
- uses: r-lib/actions/check-r-package@v1
9966

10067
- name: Show testthat output
10168
if: always()

.github/workflows/pkgdown.yaml

+7-27
Original file line numberDiff line numberDiff line change
@@ -15,42 +15,22 @@ jobs:
1515
if: ${{ github.event_name == 'push' || startsWith(github.head_ref, 'pkgdown/') }}
1616
runs-on: ubuntu-18.04
1717
env:
18-
RSPM: https://packagemanager.rstudio.com/cran/__linux__/bionic/latest
1918
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
2019
steps:
2120
- uses: actions/checkout@v2
2221

2322
- uses: r-lib/actions/setup-r@v1
24-
id: install-r
23+
with:
24+
use-public-rspm: true
2525

2626
- uses: r-lib/actions/setup-pandoc@v1
2727

28-
- name: Install pak and query dependencies
29-
run: |
30-
install.packages("pak", repos = "https://r-lib.github.io/p/pak/dev/")
31-
saveRDS(pak::pkg_deps("local::.", dependencies = TRUE), ".github/r-depends.rds")
32-
shell: Rscript {0}
33-
34-
- name: Cache R packages
35-
uses: actions/cache@v2
28+
- uses: r-lib/actions/setup-r-dependencies@v1
3629
with:
37-
path: ${{ env.R_LIBS_USER }}
38-
key: ${{ runner.os }}-${{ steps.install-r.outputs.installed-r-version }}-1-${{ hashFiles('.github/r-depends.rds') }}
39-
restore-keys: ${{ runner.os }}-${{ steps.install-r.outputs.installed-r-version }}-1-
40-
41-
- name: Install system dependencies
42-
if: runner.os == 'Linux'
43-
run: |
44-
pak::local_system_requirements(execute = TRUE)
45-
pak::pkg_system_requirements("pkgdown", execute = TRUE)
46-
shell: Rscript {0}
47-
48-
- name: Install package and dependencies
49-
run: |
50-
pak::local_install_dev_deps(upgrade = TRUE)
51-
pak::pkg_install("r-lib/pkgdown")
52-
pak::pkg_install("rstudio/quillt")
53-
shell: Rscript {0}
30+
extra-packages: |
31+
r-lib/pkgdown
32+
rstudio/quillt
33+
needs: website
5434

5535
- name: Install package
5636
run: R CMD INSTALL .

DESCRIPTION

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: rmarkdown
22
Type: Package
33
Title: Dynamic Documents for R
4-
Version: 2.11.2
4+
Version: 2.11.3.9000
55
Authors@R: c(
66
person("JJ", "Allaire", role = "aut", email = "[email protected]"),
77
person("Yihui", "Xie", role = c("aut", "cre"), email = "[email protected]", comment = c(ORCID = "0000-0003-0645-5666")),
@@ -25,6 +25,7 @@ Authors@R: c(
2525
person("Devon", "Ryan", role = "ctb", email = "[email protected]", comment = c(ORCID = "0000-0002-8549-0971")),
2626
person("Frederik", "Aust", role = "ctb", email = "[email protected]", comment = c(ORCID = "0000-0003-4900-788X")),
2727
person("Jeff", "Allen", role = "ctb", email = "[email protected]"),
28+
person("Jonathan", "Gilligan", role = "ctb", email = "[email protected]", comment = c(ORCID = "0000-0003-1375-6686")),
2829
person("JooYoung", "Seo", role="ctb", comment = c(ORCID = "0000-0002-4064-6012")),
2930
person("Malcolm", "Barrett", role = "ctb"),
3031
person("Rob", "Hyndman", role = "ctb", email = "[email protected]"),

NEWS.md

+9-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,15 @@
11
rmarkdown 2.12
22
================================================================================
33

4+
- `html_document` output allows `lib_dir` to point to a parent of the output
5+
directory if the `allow_uptree_lib_dir` parameter is set to `TRUE`. This used
6+
to throw an error, "The path <file> does not appear to be a descendant of
7+
<dir>". This makes it possible to have a directory structure for HTML output
8+
where there is a shared master library with css, javascript, etc. and separate
9+
child directories with RMarkdown files. #146 and #1859.
10+
11+
- Added a global option `rmarkdown.html_dependency.header_attr` (`TRUE` by default). It can be set to `FALSE` to opt-out the HTML dependency `html_dependency_header_attrs()` in documents based on `html_document_base()` (thanks, @salim-b rstudio/bookdown#865, @maelle r-lib/downlit#1538).
12+
413
- `draft()` now works with `devtools::load_all()` and **testthat** when used in other packages.
514

615
rmarkdown 2.11
@@ -16,7 +25,6 @@ rmarkdown 2.11
1625

1726
- The previously unexported function `convert_ipynb()` is exported now (thanks, @acircleda).
1827

19-
2028
rmarkdown 2.10
2129
================================================================================
2230

0 commit comments

Comments
 (0)