R/ensure_shell.R

#' @export 
ensure_shell <- function(blogdir = ".") {
    shell <- paste(blogdir, "shell.Rmd", sep = "/")
    if (!file.exists(shell)) {
        x <- c("",
               '```{r child="content.Rmd"}',
               '```')
        write(x, shell)
    }
}
dnegrey/blogr documentation built on May 15, 2019, 9:38 a.m.