Bash functions to separate file + rmd2html