Skip to content

Commit

Permalink
Major modifications for customization of the templates
Browse files Browse the repository at this point in the history
  • Loading branch information
Renan Souza committed May 8, 2020
1 parent 1cbf642 commit 685a7a7
Show file tree
Hide file tree
Showing 36 changed files with 1,297 additions and 1,820 deletions.
18 changes: 12 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
__pycache__
*.aux
*.log
*.out
*.pdf
**/*.pyc*
**/*dist*
**/*egg*
**/*build*
/.idea
**/*.log
**/*.pdf
**/__pycache__
**/*.aux
**/*.out
venv
auto
*pdf*
**/*.DS_Store
26 changes: 16 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@
#
# Brandon Amos <http://bamos.github.io> and
# Ellis Michael <http://ellismichael.com>
# Modified by Renan Souza <https://renan-souza.github.io>

WEBSITE_DIR=$(HOME)/repos/website

# Assuming that both the cv and github.io directories are in same parent directory `..` so the following line can work
WEBSITE_DIR=$(shell find $(shell pwd)/../*github* | head -n 1)
WEBSITE_PDF=$(WEBSITE_DIR)/data/cv.pdf
WEBSITE_MD=$(WEBSITE_DIR)/_includes/cv.md
WEBSITE_INCLUDES=$(WEBSITE_DIR)/_includes
WEBSITE_DATE=$(WEBSITE_DIR)/_includes/last-updated.txt

TEMPLATES=$(shell find templates -type f)
Expand All @@ -15,6 +18,8 @@ TEX=$(BUILD_DIR)/cv.tex
PDF=$(BUILD_DIR)/cv.pdf
MD=$(BUILD_DIR)/cv.md



ifneq ("$(wildcard cv.hidden.yaml)","")
YAML_FILES = cv.yaml cv.hidden.yaml
else
Expand All @@ -29,33 +34,34 @@ $(BUILD_DIR):
mkdir -p $(BUILD_DIR)

public: $(BUILD_DIR) $(TEMPLATES) $(YAML_FILES) generate.py
./generate.py cv.yaml
./generate.py $(YAML_FILES)

$(TEX) $(MD): $(TEMPLATES) $(YAML_FILES) generate.py
./generate.py $(YAML_FILES)
./generate.py $(YAML_FILES) -t all_publications -m
./generate.py $(YAML_FILES) -t events -m

$(PDF): $(TEX) publications/*.bib
# TODO: Hack for biber on OSX.
rm -rf /var/folders/8p/lzk2wkqj47g5wf8g8lfpsk4w0000gn/T/par-62616d6f73

latexmk -pdf -cd- -jobname=$(BUILD_DIR)/cv $(BUILD_DIR)/cv
latexmk -c -cd $(BUILD_DIR)/cv
open $(BUILD_DIR)/cv.pdf

viewpdf: $(PDF)
gnome-open $(PDF)

stage: $(PDF) $(MD)
cp $(PDF) $(WEBSITE_PDF)
cp $(MD) $(WEBSITE_MD)
cp $(BUILD_DIR)/*.md $(WEBSITE_INCLUDES)
date +%Y-%m-%d > $(WEBSITE_DATE)

jekyll: stage
./generate.py $(YAML_FILES) -o $(WEBSITE_DIR)/_config.yml
cd $(WEBSITE_DIR) && bundle exec jekyll server

push: stage
git -C $(WEBSITE_DIR) add $(WEBSITE_PDF) $(WEBSITE_MD) $(WEBSITE_DATE)
git -C $(WEBSITE_DIR) commit -m "Update cv."
git -C $(WEBSITE_DIR) push

clean:
rm -rf $(BUILD_DIR)/cv*
rm -rf $(BUILD_DIR)/*cv*
rm -rf $(BUILD_DIR)/*md
rm -rf $(WEBSITE_INCLUDES)/*md
3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
[![Linux Build Status](https://travis-ci.org/bamos/cv.svg?branch=master)](https://travis-ci.org/bamos/cv)
[![Windows Build Status](https://ci.appveyor.com/api/projects/status/l06od9i143im059m?svg=true)](https://ci.appveyor.com/project/bamos/cv)
[![Python Dependency Status](https://gemnasium.com/bamos/cv.svg)](https://gemnasium.com/bamos/cv)

# About
This repo contains the source I use to automatically generate
Expand Down
48 changes: 0 additions & 48 deletions attic/blog-info.py

This file was deleted.

35 changes: 0 additions & 35 deletions attic/github-info.py

This file was deleted.

Loading

0 comments on commit 685a7a7

Please sign in to comment.