incorporate code listings from an external file in knitr/markdown
问题 I would like to incorporate listings of code drawn from external files in an Rmarkdown file. I would like it pretty (syntax highlighting, auto-indentation, etc.). The code is not R code (otherwise I could use some of the existing tricks to pretty-print R functions) - specifically, it's BUGS and Stan code. I'm not necessarily targeting LaTeX/PDF output: otherwise I could use the listings package. I'd like to be able to incorporate the files without an unwieldy external cat firstpart.rmd