Skip to content
Snippets Groups Projects
Commit 53c0a7f2 authored by François Michonneau's avatar François Michonneau
Browse files

make sure that checkpoint version is 0.4.0 or higher

parent df9ba824
Branches
Tags
No related merge requests found
......@@ -6,12 +6,12 @@ generate_md_episodes <- function() {
if (!require("stringr"))
stop("The package stringr is required for generating the lessons.")
if (require("checkpoint")) {
if (require("checkpoint") && packageVersion("checkpoint") >= '0.4.0') {
required_pkgs <-
checkpoint:::scanForPackages(project = "_episodes_rmd",
verbose=FALSE, use.knitr = TRUE)$pkgs
} else {
stop("The checkpoint package is required to build the lessons.")
stop("The checkpoint package (>= 0.4.0) is required to build the lessons.")
}
missing_pkgs <- required_pkgs[!(required_pkgs %in% rownames(installed.packages()))]
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment