Skip to content

Commit 3f9def2

Browse files
committed
Try to disable chunks on GH actions
1 parent 8739fd6 commit 3f9def2

4 files changed

Lines changed: 16 additions & 4 deletions

File tree

vignettes/workflow.Rmd

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ knitr::opts_chunk$set(
1212
collapse = TRUE,
1313
comment = "#>"
1414
)
15-
is_ghactions <- identical(Sys.getenv("CI"), "true")
15+
is_ghactions <- tolower(Sys.getenv("GITHUB_ACTIONS")) == "true"
16+
is_ci <- tolower(Sys.getenv("CI")) %in% c("true", "1", "yes")
17+
18+
is_ghactions <- is_ghactions || is_ci
1619
1720
```
1821

vignettes/workflow_120min_40mm.Rmd

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ knitr::opts_chunk$set(
1212
collapse = TRUE,
1313
comment = "#>"
1414
)
15-
is_ghactions <- identical(Sys.getenv("CI"), "true")
15+
is_ghactions <- tolower(Sys.getenv("GITHUB_ACTIONS")) == "true"
16+
is_ci <- tolower(Sys.getenv("CI")) %in% c("true", "1", "yes")
17+
18+
is_ghactions <- is_ghactions || is_ci
1619
1720
```
1821

vignettes/workflow_eisenstadt-2005.Rmd

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ knitr::opts_chunk$set(
1212
collapse = TRUE,
1313
comment = "#>"
1414
)
15-
is_ghactions <- identical(Sys.getenv("CI"), "true")
15+
is_ghactions <- tolower(Sys.getenv("GITHUB_ACTIONS")) == "true"
16+
is_ci <- tolower(Sys.getenv("CI")) %in% c("true", "1", "yes")
17+
18+
is_ghactions <- is_ghactions || is_ci
1619
#is_ghactions <- FALSE
1720
```
1821

vignettes/workflow_v2.Rmd

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ knitr::opts_chunk$set(
1212
collapse = TRUE,
1313
comment = "#>"
1414
)
15-
is_ghactions <- identical(Sys.getenv("CI"), "true")
15+
is_ghactions <- tolower(Sys.getenv("GITHUB_ACTIONS")) == "true"
16+
is_ci <- tolower(Sys.getenv("CI")) %in% c("true", "1", "yes")
17+
18+
is_ghactions <- is_ghactions || is_ci
1619
1720
```
1821

0 commit comments

Comments
 (0)