Skip to content

paulfioravanti/resume

Repository files navigation

Resume

Build Status

This is a Ruby command line interface (CLI) application that generates my resume. I made it in order to teach myself a bit about the Ruby PDF generation library Prawn. Railscast #153 is also a good resource for learning about it.

Text is deliberately obfuscated in the JSON files that contain the resume content with Base64 to ensure people generate the PDF in order to be able to read anything.

Blog Post and Presentation

I wrote a companion blog post for this project:

It outlines some reasons for making it, as well as some of the technical challenges and quirks.

I also did a lightning talk about this project at the Ruby on Rails Oceania Meetup on 10 May 2016 (slide deck). No video of the talk exists, unfortunately. Perhaps I will re-record it again some time...

Setup

git clone https://github.com/paulfioravanti/resume.git
cd resume
bundle install

Dependencies

  • Ruby 3.2.2
  • i18n, Prawn and Prawn-Table (if you don't have the specific versions of the gems, you will be prompted to install them)
  • RSpec, if you want to run the tests

Usage

Generate Resume

Generate the resume in the following languages:

🇬🇧 bin/resume
🇮🇹 bin/resume -l it
🇯🇵 bin/resume -l ja

Help: bin/resume -h

Tests

Run the tests:

bin/rspec

Coverage Report

View the Simplecov test coverage report:

open coverage/index.html

Documentation

Generate the YARD documentation:

bin/yardoc

One Sheet Resume

Generate the "one sheet" version of the resume (the whole app and specs in a single file called resume.rb).

Create

If I sent my resume to you directly, it would have been generated from this rake task:

bin/rake resume

Generate One Sheet

The resume PDF can be generated from the one sheet in a similar way as the CLI app:

🇬🇧 ruby resume.rb
🇮🇹 ruby resume.rb -l it
🇯🇵 ruby resume.rb -l ja

One Sheet Specs

The specs can also be run directly on the one sheet resume:

rspec resume.rb

Delete Assets

If there are ever any errors or issues related to the downloading of remote assets that cause the resume to not be able to be generated, you can run the following rake task to delete all resume-related assets from the local tmpdir:

bin/rake resume:delete_assets

Issues

  • It doesn't seem possible yet in Prawn to make an embedded image a clickable link. Until support is possible (if ever), I've simply pulled in images from Dropbox and overlaid a transparent text link on top to simulate clicking an image. More discussion on this issue is at this StackOverflow thread.