From 4c336fccbca2bcfa8089af36a476cd2f2dc5bc49 Mon Sep 17 00:00:00 2001 From: Eve Perry Date: Fri, 24 Sep 2021 18:26:01 -0700 Subject: [PATCH] create analyses directory --- R/create.R | 3 +++ 1 file changed, 3 insertions(+) diff --git a/R/create.R b/R/create.R index 6915784..0a2bc8d 100644 --- a/R/create.R +++ b/R/create.R @@ -38,6 +38,9 @@ create_bhhi_site = function(dir, title, # add the analyses collection site_yaml$collections$analyses$categories = TRUE + # create the analyses directory if it doesn't exist + if (!dir.exists(file.path(dir, "_analyses"))) dir.create(file.path(dir, "_analyses")) + # read in index.Rmd index_yaml <- readLines(file.path(dir, "index.Rmd"), n = 5) # delete existing index.Rmd