With plain HTML output, you could try the xfun package:
```{r install}
devtools::install_github('yihui/xfun')
# embed_file() requires a few more packages
xfun::pkg_load2(c('base64enc', 'htmltools', 'mime'))
```
```{r echo=FALSE}
# a single file
xfun::embed_file('source.Rmd')
# multiple files
xfun::embed_files(c('source.Rmd', 'data.csv'))
# a directory
xfun::embed_dir('data/', text = 'Download full data')
```