My CV as a JSON document.
Find a file
Dan Anglin 84b29f0467
feat: build the magefile into a binary
This commit builds the magefile into a binary during the docker build
stage.
The Dockerfile is updated to include a multi-stage build where the first
stage compiles the binary and the second stage builds the final
cv-builder image.
The final image is now based on debian:buster instead of
golang:<VERSION>-buster which significantly reduces the image's size.
2020-09-13 22:50:17 +01:00
.aspell feat: add experiences at Experian 2020-09-13 13:47:40 +01:00
.gitlab/ci feat: build the magefile into a binary 2020-09-13 22:50:17 +01:00
data feat: add experiences at Experian 2020-09-13 13:47:40 +01:00
docker feat: build the magefile into a binary 2020-09-13 22:50:17 +01:00
helpers refactor: move spellcheck to helpers package 2020-09-13 14:24:29 +01:00
template/tex style: ensure tex templates uses tex extension 2020-08-20 00:50:44 +01:00
.dockerignore feat: build the magefile into a binary 2020-09-13 22:50:17 +01:00
.gitignore refactor: replace make with mage 2020-08-09 05:08:30 +01:00
.gitlab-ci.yml ci: add a release pipeline 2020-08-15 20:22:00 +01:00
go.mod refactor: replace make with mage 2020-08-09 05:08:30 +01:00
go.sum refactor: replace make with mage 2020-08-09 05:08:30 +01:00
LICENSE Add MIT LICENSE 2019-08-22 08:18:39 +00:00
mage.go refactor: replace make with mage 2020-08-09 05:08:30 +01:00
magefile.go refactor: move spellcheck to helpers package 2020-09-13 14:24:29 +01:00
README.md ci: add a release pipeline 2020-08-15 20:22:00 +01:00

My CV Project

Table of Contents

Overview

This project parses my CV that is written as a JSON document and generates a PDF document. This project contains a Go application and uses the ConTeXt document processor which are used to parse and generate a PDF document from the CV. I chose to use ConTeXt as the document processor because it gives me more control to edit page layouts, configure fonts, perform additional formatting and add custom functionality.

Support for other formats such as HTML will be available soon.

View/Download the CV

The latest build of the generated PDF document can be downloaded from the release page of the project in GitLab.

Dependencies

If you are interested in generating the PDF document on your own machines or want to use the project to generate your own CV, then below is a list of dependencies that you'll need to install:

  • Go - Please go here to download the latest version of the Go programming language.
  • ConTeXt - I recommend installing version 1.02 or higher. Please go here for installation instructions for your distribution.
  • The Carlito font (ttf-carlito) - In prevous iterations of my CV I used the Calibri font. Carlito is the free, metric compatible alternative to this and is specified in the TEX template.
    • For Ubuntu/Debian installation you can use apt:
      $ apt-get install font-crosextra-carlito
      
    • For Arch Linux you can use pacman:
      $ pacman -S ttf-carlito
      
    • Alternatively you can download the font from https://fontlibrary.org/en/font/carlito
    • Once this font is installed you'll need to update ConTeXt so it can find the font when generating the PDF:
      $ OSFONTDIR=/usr/share/fonts
      $ mtxrun --script fonts --reload
      

Once the dependencies are installed you can follow the Generating the PDF Document section below.

Using Docker as an alternative

If you prefer not to install the dependencies above, I have created a Docker image installed with the above dependencies. This image is used to build and publish the CV via the GitLab CI pipleines. The image is built using this Dockerfile and is pullable from GitLab's container registry.

To use the image follow the steps below:

  1. Make sure you've clone this project to your workspace:

    $ git clone https://gitlab.com/dananglin/cv.git
    $ cd cv
    
  2. Create the docker container and mount the current directory to the /project directory inside the container:

    $ docker run --rm -it -v ${PWD}:/project registry.gitlab.com/dananglin/cv/cv-builder:master-5fbdaa5a bash
    
    # Once inside the docker container
    $ cd /project
    
  3. Follow the Generating the PDF Document section below.

Generating the PDF Document

The PDF document can be generated by running the following command:

$ go run mage.go pdf

The PDF generation is completed in two steps:

  1. The Go application will generate a TEX file using the JSON document and the TEX template files located in the template directory.
  2. ConTeXt is then used to generate the PDF document from the generated TEX file.

Inspirations

  • The Markdown Resume - This project uses ConTeXt and pandoc to convert Markdown based CVs into multiple formats including PDF, HTML and DOCX. This is where I discovered ConTeXt.
  • melkir/resume - This project generates CVs using Go and LaTeX.