Is hyperref really the best way to add metadata to a TeX file?
You could use the \pdfinfo
command of pdfTeX to add meta data. For example:
\pdfinfo{
/Title (example.pdf)
/Creator (TeX)
/Producer (pdfTeX 1.40.0)
/Author (Seamus)
/Subject (Example)
/Keywords (pdflatex, latex,pdftex,tex)}
There's no need to load a package for that purpose. This command is explained in the pdfTeX documentation.
There is xmpincl
which allows you to add arbitrary metadata in the Adobe XMP (Extensible Metadata Platform) format. But you have to write a separate XML file to do this. I always thought there should be a LaTeX way to create an XMP file on the first pass and embed it in the PDF on the second pass. But so far I know of none.
hyperxmp – Embed XMP metadata within a LATEX document
http://www.ctan.org/pkg/hyperxmp
" ... The package integrates seamlessly with hyperref
and requires virtually no modifications to documents that already exploit hyperref's mechanisms for specifying PDF metadata..
"XMP (eXtensible Metadata Platform) is a mechanism proposed by Adobe for embedding document metadata within the document itself. The metadata is designed to be easy to extract, even by programs that are oblivious to the document's file format. Most of Adobe's applications store XMP metadata when saving files. Now, with the hyperxmp
package, it is trivial for LaTeX document authors to store XMP metadata in their documents as well.