-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathMakefile
60 lines (41 loc) · 1.27 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
.PHONY: docs servedocs doctoc
# crear entorno virtual e instalar paquetes
# remover entorno virtual
# crear cronfile
# instalar cronfile
# correr rutina diaria
# Las dos recetas siguientes fueron tomadas de
# http://blog.bottlepy.org/2012/07/16/virtualenv-and-makefiles.html
venv: venv/bin/activate
venv/bin/activate: requirements.txt
test -d venv || virtualenv venv
venv/bin/pip install -r requirements/base.txt
touch venv/bin/activate
# Las siguientes recetas son especÃficas a nuestro repositorio
install_cron: cron_jobs
@echo "ROOTDIR=$$PWD" >> .cronfile
@echo "PYTHON=$$PWD/venv/bin/python" >> .cronfile
cat cron_jobs >> .cronfile
crontab .cronfile
rm .cronfile
touch cron_jobs
setup: venv install_cron
test -d logs || mkdir logs
test -d archivo || mkdir archivo
clean:
rm -rf venv/
cat /dev/null | crontab
SHELL = bash
servedocs:
mkdocs serve
mkdocsdocs:
mkdocs build
rsync -vau --remove-source-files site/ docs/
rm -rf site
docs: mkdocsdocs
doctoc: ## generate table of contents, doctoc command line tool required
## https://github.com/thlorenz/doctoc
doctoc --maxlevel 4 --github --title "## Indice" docs/
find docs/ -name "*.md" -exec bash fix_github_links.sh {} \;
pdf:
mkdocs_datosgobar md2pdf mkdocs.yml docs/monitoreo-apertura-docs.pdf