Skip to content

Commit 125a611

Browse files
committed
Do not eval vignettes on R universe (closes r-universe-org/help#171)
1 parent 5e4163b commit 125a611

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

vignettes/analyse-rpackages.Rmd

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,28 +18,28 @@ knitr::opts_chunk$set(
1818
)
1919
2020
is_ghactions <- identical(Sys.getenv("CI"), "true") && identical(Sys.getenv("GH_ACTIONS_KWB_R"), TRUE)
21-
21+
local <- FALSE
2222
```
2323

2424
# Get Metadata for All KWB-R Github Repos
2525

2626
For all Github repos also includes non R packages
2727

28-
```{r, eval = TRUE}
28+
```{r, eval = is_ghactions}
2929
pkgmeta::write_github_repos_json()
3030
```
3131

3232
# Get Public KWB-R Github Package
3333

3434
Now limit only "public" KWB-R repos which are R packages.
3535

36-
```{r, eval = TRUE}
36+
```{r, eval = is_ghactions}
3737
pkgs <- pkgmeta::get_github_packages()
3838
```
3939

4040
# Define paths
4141

42-
```{r, eval = !is_ghactions}
42+
```{r, eval = local}
4343
# Define paths and resolve placeholders
4444
paths_list <- list(
4545
root_dir = tempdir(),
@@ -59,7 +59,7 @@ paths <- kwb.utils::resolve(paths_list, root_dir = tempdir())
5959

6060
in own library required for "codemetar" and "pkgnet" reports
6161

62-
```{r, echo = !is_ghactions, eval = !is_ghactions}
62+
```{r, echo = FALSE, eval = local}
6363
fs::dir_create(paths$pkglib, recursive = TRUE)
6464
6565
withr::with_libpaths(new = paths$pkglib, code = {
@@ -90,7 +90,7 @@ pkgmeta::travis_pkg_install_script()
9090

9191
required for pkgnet "covr":
9292

93-
```{r, echo = !is_ghactions, eval = !is_ghactions}
93+
```{r, echo = TRUE, eval = local}
9494
9595
fs::dir_create(
9696
path = c(paths$pkgsource_zip_dir, paths$pkgsource_unzip_dir),
@@ -121,7 +121,7 @@ invisible(lapply(zipfiles, function(x) {
121121

122122
Generating "codemetar.json" file
123123

124-
```{r, echo = !is_ghactions, eval = !is_ghactions}
124+
```{r, echo = TRUE, eval = local}
125125
pkgs <- pkgmeta::get_github_packages()
126126
127127
codemeta <- pkgmeta::create_pkg_codemeta(pkgs, libpath = paths$pkglib)
@@ -149,7 +149,7 @@ pkgmeta::write_pkg_codemeta_json(codemeta)
149149

150150
Create Reports with "pkgnet
151151

152-
```{r, echo = !is_ghactions, eval = !is_ghactions}
152+
```{r, echo = TRUE, eval = local}
153153
fs::dir_create(paths$pkgnet_dir, recurse = TRUE)
154154
155155
withr::with_libpaths(new = c(paths$pkglib, .libPaths()),

vignettes/codemetar-analysis.Rmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ wordcloud2::wordcloud2(maintainer,
136136
```
137137

138138

139-
```{r, eval = TRUE}
139+
```{r, eval = is_ghactions}
140140
## number of co-authors ...
141141
purrr::map_int(corpus, function(r) length(r$author)) %>%
142142
tibble::enframe() %>%

0 commit comments

Comments
 (0)