-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
43 lines (29 loc) · 971 Bytes
/
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
# Get the version of the R package and save it
PKG_VERSION:=$(shell Rscript -e 'x<-readLines("DESCRIPTION");cat(gsub(".+[:]\\s*", "", x[grepl("^Vers", x)]))')
# Capture the current directory
DIR_NAME:=$(shell basename `pwd`)
PKG_NAME:= epiworldRShiny
which:
@echo "PKG_VERSION: $(PKG_VERSION)"
@echo "PKG_NAME: $(PKG_NAME)"
docs:
Rscript --vanilla -e 'devtools::document()'
build:
cd .. && R CMD build $(DIR_NAME)
install:
cd .. && R CMD INSTALL $(PKG_NAME)_$(PKG_VERSION).tar.gz
run:
Rscript --vanilla -e 'epiworldRShiny::epiworldRShiny()'
check:
cd .. && R CMD check $(PKG_NAME)_$(PKG_VERSION).tar.gz
docker-build:
docker build -t gvegayon/epiworldrshiny .
docker-push:
docker push gvegayon/epiworldrshiny
docker-run:
docker run -i --rm -v$(PWD):/epiworld/ uofuepibio/epiworldrshiny
deploy:
Rscript --vanilla epishiny/deploy.R
README.md: README.Rmd
Rscript -e 'rmarkdown::render("README.Rmd")'
.PHONY: docs build install run check docker-build