forked from metrumresearchgroup/pmtables
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
66 lines (50 loc) · 1.3 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
SHELL := /bin/bash
PACKAGE=pmtables
VERSION=$(shell grep Version DESCRIPTION |awk '{print $$2}')
TARBALL=${PACKAGE}_${VERSION}.tar.gz
PKGDIR=.
CHKDIR=.
all:
make doc
make install
make build
install:
R CMD INSTALL .
build:
R CMD build .
doc:
Rscript -e 'devtools::document()'
readme:
Rscript -e 'rmarkdown::render("README.Rmd")'
test:
make install
Rscript -e 'testthat::test_local()'
covr:
Rscript inst/covr/covr.R
check:
make doc
make build
R CMD CHECK --no-manual $(TARBALL)
pkgdown:
Rscript -e "options(pkdown.internet = FALSE); pkgdown::build_site()"
data:
cd data-raw && Rscript data.R
demo-doc:
Rscript -e 'rmarkdown::render("inst/demo-table.Rmd", clean=TRUE)'
Rscript -e 'rmarkdown::render("inst/demo-pmtable.R", clean=TRUE)'
Rscript -e 'rmarkdown::render("inst/demo-pipe.Rmd", clean=TRUE)'
Rscript -e 'rmarkdown::render("inst/demo-longtable.Rmd", clean=TRUE)'
Rscript -e 'rmarkdown::render("inst/demo-sanitize.Rmd", clean=TRUE)'
quick:
make doc
make build
R CMD check $(TARBALL) --ignore-vignettes --no-manual --no-tests --no-install
bump-dev:
Rscript -e 'usethis::use_version("dev")'
tag-version:
git tag $(VERSION)
git push origin $(VERSION)
demo-check:
Rscript -e 'testthat::test_file("tests/testthat/test-demo-check.R")'
spelling:
Rscript -e "spelling::spell_check_package('.')"