Skip to content

Commit

Permalink
Merge pull request #62 from fmichonneau/fix-knitr-env
Browse files Browse the repository at this point in the history
use anonymous function to generate markdown files
  • Loading branch information
Francois Michonneau authored and GitHub committed Jun 22, 2016
2 parents 0c9c153 + 4e8365b commit 02b4ec1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bin/generate_md_episodes.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ if (!require("stringr"))
src_rmd <- list.files(pattern = "??-*.Rmd$", path = "_episodes_rmd", full.names = TRUE)
dest_md <- file.path("_episodes", gsub("Rmd$", "md", basename(src_rmd)))

for (i in seq_along(src_rmd)) {
knitr::knit(src_rmd[i], output = dest_md[i])
}
mapply(function(x, y) {
knitr::knit(x, output = y)
}, src_rmd, dest_md)

0 comments on commit 02b4ec1

Please sign in to comment.