- Notifications
You must be signed in to change notification settings - Fork3
A JSON to HTML resume generator
License
SergChr/qcv
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
qcv
is a tool to generate HTML resume from JSON template.
The tool allows to have one JSON file where the resume information placed. It can be stored in agit
repository to make the updating process more seamless. There could be branching applied for different versions; the diffs are more simpler to track.No moreCV_1.pdf
,CV_1_updated.pdf
,CV_1_updated_for_facebook.pdf
.
No need to move between different services that generate a resume or/and store it.
The tool generates a HTML file based on a HTML template that can be customized.
The tool replaces variables in a HTML template (seesrc/assets/themes
) with corresponding values in the JSON template. Example:This is a HTML template
<div>{{basics.name}}<div>
The JSON template is
{"basics": {"name":"John Doe" }}
So the result will be as follows:
<div>John Doe</div>
This is the JSON template example below. It will be generated by theinit
command. It createscv.json
file with the similar content:
{"basics": {"name":"John Doe","label":"Programmer","email":"john@gmail.com","phone":"(912) 555-4321","website":"http://johndoe.com","summary":"A brief summary on who I am","location": {"country":"The Johnited States Of Doe","address":"2712 Broadway St","city":"San Francisco" },"profiles": [{"network":"Twitter","username":"john","url":"http://twitter.com/john" }] },"work": [{"company":"Company","position":"President","website":"http://company.com","start_date":"2013-01-01","end_date":"2014-01-01","summary":"Description..." }],"projects": [{"name":"An app to track time","description":"A web and mobile application that allowed 2500 people to track their working time" }],"education": [{"institution":"University","area":"Software Development","study_type":"Bachelor","start_date":"2011-01-01","end_date":"2013-01-01","courses": ["DB1101 - Basic SQL" ],"location":"Washington DC, US" }],"skills": [{"name":"Web Development" }],"languages": [{"language":"English","level":"Native speaker" }] }
Put your information into this file. Then use thebuild simple
command to generate thecv.html
output.
There is an ability to build your custom HTML template and generate a resume from it. Example:
$ qcv build-from my_theme.html
As a reference, you could use "simple" theme (src/assets/themes/simple/index.html
).
A value inside{{ root_key }}
in a HTML template looks up for a keyroot_key
in thecv.json
file and replaces{{ root_key }}
with the corresponding value. Nested keys should be written as{{ root.nested.more_nested }}
. Say, we have the followingcv.json
:
{"basics": {"name":"John Doe","label":"Programmer", },}
A theme could be:
<sectionid="main-info"><h1>{{ basics.name }}</h1><!-- It doesn't matter if you use wrapping spaces or not inside {{ }} --><h2>{{basics.label}}</h2></section>
CSS styles could be inside<style>
as well as Javascript code. A template is just a HTML with{{ }}
that will be replaced with values from thecv.json
.
cv.json
has arrays with objects. Like:
{"basics": {"profiles": [{"network":"Twitter","username":"john","url":"http://twitter.com/john" }] }}
To map array values, the syntax is:
<!-- Point a key which value is an array -->{! basics.profiles<!-- Note the number of braces here: { } not {{ }} --><!-- Number of spaces inside { } also doesn't matter --><div>{network}</div><p>{username}</p><ahref="{url}">{url}</a>!}
If you have Cargo installed, downloadqcv crate and use it globally in a terminal.
$ cargo install qcv# Usage$ qcv init$ qcv build simple
Download an archive in thereleases section. E.g. for Ubuntu, download...x86_64-unknown-linux-gnu.tar.gz
, unpack it, then use as follows:
# Create a JSON template./qcv init# Generate HTML file./qcv build simple
Use this method if you have Rust ecosystem installed.
$ git clone<repo># Create cv.json template$ cargo run init# Build cv.html result based on cv.json$ cargo run build simple
About
A JSON to HTML resume generator