mathr / blog / #

Writing a CV with LaTeX

I needed to write a CV recently. It took me about two hours to come up with something coherent, in plain text. Then I needed to format it into a PDF document, which took another two hours, with lots of internet searches for specific layout tweaks. Here's what I came up with.

Using the standard LaTeX article class seemed simplest, as my CV isn't a traditional academic or corporate one.


I have a couple of non-ASCII accented characters in the text, so I enabled UTF-8 support.


I wanted A4 paper size, with 3cm margins, but also space in the right-hand margin to show the URLs for hyperlinks in the main text (in case someone prints the document and wants to find the referenced content). So the outer margin becomes 8cm, with 5cm for marginal notes, separated from the text by 1cm. See this diagram for more information.


I wanted links to be coloured matching the brown on my website, instead of the default ugly surrounding boxes that the hyperref package uses by default. I disable internal links to footnotes, because they will be in the margin right next to the relevant text. I also disable showing the bookmarks pane in PDF viewers by default, as the document isn't long enough to merit it.


I wanted the fonts to match my website too, using LM Sans. The default in LaTeX is serif, but it's a one-line addition to use sans-serif.


I wanted a wider line spacing, with no paragraph indent - instead adding some vertical space between paragraphs.


As mentioned earlier, I wanted URLs to be visible in the margin, and using footnotes seemed easiest. The footmisc package allows footnotes to be placed in the margin. I ended up with 10 footnotes, but I wanted to start their numbering at 0 instead of 1 - I found the perpage package had an option for initial numbering but there may be a better way.


Now I can define a macro to expand \link{title}{url} into an inline link with a title, coupled with a footnote link with the URL visible:


The document title is my name in bold, with my email address underneath (as a hyperlink too).

\title{\bfseries Claude Heiland-Allen}

Preamble complete, here comes the document. I remove page numbering because there is only one page. Document text omitted for brevity.




Here's the final output PDF.