I'm using Sweave to automate the creation of a report, and I want to include a PDF into my document, but the PDF and its name are updated daily (because they are produced using Sweave).
For example today, my PDF's name is report_2016-01-04.pdf; tomorrow it'll be report_2016-01-05.pdf.
(Obviously) This isn't working for me...
\documentclass[10pt]{report}
\usepackage[yyyymmdd]{datetime}
\renewcommand{\dateseparator}{-}
\begin{document}
\includepdf[pages={1,2,3}]{report_\today.pdf}
\end{document}
\todayto the log via\tyoeoutto to confirm that is is not adding extra things that might confuse a file inclusion – daleif Jan 04 '16 at 20:21