-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
74 lines (54 loc) · 2.25 KB
/
Copy pathMakefile
File metadata and controls
74 lines (54 loc) · 2.25 KB
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
all: test check
echo "Done!"
# admin
build:
R --slave -e "devtools::build()"
install:
R --slave -e "remotes::install_local('.', upgrade = 'never', force = TRUE)"
clean:
rm -rf man/*
rm -rf docs/*
rm -rf inst/doc/*
# documentation
docs: man readme vigns site
man:
R --slave -e "devtools::document()"
readme:
R --slave -e "rmarkdown::render('README.Rmd')"
test:
R --slave -e "devtools::test()" > test.log 2>&1
rm -f tests/testthat/Rplots.pdf
vigns:
R --slave -e "devtools::build_vignettes()"
cp -R doc inst/
purl_vigns:
R --slave -e "lapply(dir('vignettes', '^.*\\\\.Rmd$$'), function(x) knitr::purl(file.path('vignettes', x), gsub('.Rmd', '.R', x, fixed = TRUE)))"
rm -f Rplots.pdf
check_vigns:
R --slave -e "f <- sapply(dir('vignettes', '^.*\\\\.Rmd$$'), function(x) {p <- file.path(tempdir(), gsub('.Rmd', '.R', x, fixed = TRUE)); knitr::purl(file.path('vignettes', x), p); p}); for (i in f) {message('\n########################################\nstarting ', basename(i), '\n########################################\n'); source(i)}"
rm -f Rplots.pdf
quicksite:
R --slave -e "pkgdown::build_site(run_dont_run = TRUE, lazy = TRUE)"
site:
R --slave -e "pkgdown::clean_site()"
R --slave -e "pkgdown::build_site(run_dont_run = TRUE, lazy = FALSE)"
# checks
quickcheck:
echo "\n===== R CMD CHECK =====\n" > check.log 2>&1
R --slave -e "devtools::check(build_args = '--no-build-vignettes', args = '--no-build-vignettes', run_dont_test = TRUE, vignettes = FALSE)" >> check.log 2>&1
check:
echo "\n===== R CMD CHECK =====\n" > check.log 2>&1
R --slave -e "devtools::check(build_args = '--no-build-vignettes', args = '--no-build-vignettes', run_dont_test = TRUE, vignettes = FALSE)" >> check.log 2>&1
wbcheck:
R --slave -e "devtools::check_win_devel()"
solarischeck:
R --slave -e "rhub::check(platform = 'solaris-x86-patched', email = 'jeffrey.hanson@uqconnect.edu.au', show_status = FALSE)"
spellcheck:
echo "\n===== SPELL CHECK =====\n" > spell.log 2>&1
R --slave -e "devtools::spell_check()" >> spell.log 2>&1
urlcheck:
R --slave -e "urlchecker::url_check()"
examples:
R --slave -e "devtools::run_examples(test = TRUE, run = TRUE);warnings()" >> examples.log
rm -f Rplots.pdf
.PHONY: vigns clean docs readme site test check checkwb build install man spellcheck