-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
85 lines (63 loc) · 1.33 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
SHELL := /bin/bash
PACKAGE=mrgsim.parallel
VERSION=$(shell grep Version DESCRIPTION |awk '{print $$2}')
TARBALL=${PACKAGE}_${VERSION}.tar.gz
PKGDIR=.
CHKDIR=.
travis:
make build
R CMD check ${TARBALL} --as-cran
test:
Rscript -e 'library(testthat)' -e 'test_file("tests/testthat.R")'
rhub:
Rscript -e 'rhub::check_for_cran()'
cran:
make doc
make build-vignettes
R CMD check ${TARBALL} --as-cran
covr:
Rscript inst/covr/covr.R
ec:
echo ${VERSION}
all:
make doc
make build
make install
.PHONY: doc
doc:
Rscript -e 'library(devtools); document()'
.PHONY: build
build:
R CMD build --md5 --no-build-vignettes $(PKGDIR)
build-vignettes:
R CMD build --md5 $(PKGDIR)
package:
make doc
make build-vignettes
make install
install:
R CMD install --install-tests ${TARBALL}
install-build:
R CMD install --build --install-tests ${TARBALL}
check:
make doc
make build
R CMD check --ignore-vignettes --no-manual ${TARBALL} -o ${CHKDIR}
unit-csv:
Rscript inst/script/unit.R
readme:
Rscript -e 'rmarkdown::render("README.Rmd")'
pkgdown:
Rscript -e 'pkgdown::build_site()'
spelling:
Rscript inst/script/_spelling.R
check-win:
Rscript -e 'devtools::check_win_devel()'
bump-dev:
Rscript -e 'usethis::use_version("dev")'
tag-version:
git tag $(VERSION)
git push origin $(VERSION)
stories:
make unit-csv
Rscript inst/script/stories.R