Created
December 4, 2012 06:50
-
-
Save wush978/4201332 to your computer and use it in GitHub Desktop.
Convert Rmd 2 md with knitr
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
argv <- commandArgs(TRUE) | |
if (!length(argv)) { | |
cat("Convert Rmd to md\n") | |
cat("Usage: <input> <output>\n") | |
quit("no") | |
} | |
if (!require(knitr)) { | |
stop("knitr is required") | |
} | |
opts_knit$set(upload.fun = image_uri, animation.fun = hook_r2swf) | |
knit(argv[1], argv[2]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment