tooling to deal with episodes written using Rmarkdown #30
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is my proposal to deal with Rmarkdown files with the new template.
Currently, episodes will live in the
_episodes_rmd
folder. These files are just like the markdown files that are normally written for lessons that don't use Rmarkdown, except they can include chunks of R code. I included an example Rmd file in this PR (_episodes_rmd/06-rmarkdown-example.Rmd)On the technical side:
make clean
_episodes_rmd
folder and if it exists, the Rmd files get converted into md files inside the_episodes
folder. This approach should mean that the Makefile will run smoothly if there is noepisodes_rmd
.It seems the Makefile can be improved, as the Rmd files get converted to md each time
make serve
ormake site
is invoked, even if the Rmd files don't change.If the approach seems reasonable, I can try to start converting a few episodes for one of our R lessons to make sure everything runs smoothly.