This is an R project for automatically building my academic CV. It's based on the idea that content and style should be separate and that a person might want different CVs for different purposes. Inspiration came from Kieran Healy for the formatting of the CV itself and Rob Hyndman for the use of Biblatex to manage the publications list.
The project consists of:
-
a
contentdirectory that contains: YAML files for the overall CV configuration, YAML files to store the data for all of the non-publication parts of the CV, and a bibtex file that contains the publications. -
a
styledirectory that contains the overall LaTeX style, as well as scripts for inserting version control information -
a
scriptsdirectory that contains R scripts for building the CV.
Creating a new CV is relatively simple.
-
Export all of your publications as a
*.bibfile -
Write all of the other sections of your CV, putting them in YAML files
-
Write an overall CV file in YAML. There are a couple of gotchas to be careful of here.
-
In the
publicationssection, each of the named sections must correspond to a declared biblatex section in the style file, e.g.jk-vita.sty. -
In the
sectionssection, the file field should contain the name of a YAML file describing that section's content. There must be a correspondingformat_sectionfunction in thestyle_functions.rfile that specifies how to display the information. For example, if you have a section file calledawards.yamland you wish to generate atexoutput document, then thetex_functions.rfile must contain aformat_awardsfunction.
-
-
Define a style file. At the moment, only LaTeX formats are supported so modify the
jk-vita.styfile as appropriate. The most important lines in here have to do with the formatting of the publications using biblatex, but there are also settings for fonts, colours, and other details. -
Build the CV. This is easy. Simply open up R, change into the
scriptsdirectory and run the following commands:
> source("generate_cv.r")
> generate_cv("../path/to/my-cv.yaml", "../path/to/my-style.sty", "output_directory")The compiling process will build a PDF and place it in the specified output directory. Compilation uses xelatex and biber so make sure these are installed on your system. If the compilation if successful, then the source files will be deleted leaving only the finished PDF. If unsuccessful, all of the source files are left so you can try to patch things up manually.