Custom script for compiling tex and markdown, using pandoc and latex