-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathpkg_build.R
40 lines (32 loc) · 959 Bytes
/
pkg_build.R
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
# cleanup
rm(list=ls()); gc(); cat("\014"); try(dev.off(), silent=T)
# working directory
setwd(dirname(rstudioapi::getSourceEditorContext()$path))
usethis::use_package("data.table")
usethis::use_package("sf")
usethis::use_package("stars")
usethis::use_package("lwgeom")
usethis::use_package("doParallel")
usethis::use_package("parallel")
usethis::use_package("foreach")
usethis::use_package("filelock")
# usethis::use_package("purrr")
usethis::use_package("iterators")
usethis::use_package("units")
usethis::use_package("mmap")
usethis::use_package('geosphere')
usethis::use_package('geos')
# library("roxygen2")
# package documentation
devtools::document()
# # vignettes
# devtools::build_vignettes()
# install package
devtools::build()
# install.packages(getwd(), repo=NULL, type='source')
devtools::install()
devtools::reload(devtools::inst('foot'))
.rs.restartR()
rmarkdown::render("README.Rmd")
pkgdown::build_site()
devtools::build_vignettes()