On 1/25/20 12:55, Gábor Csárdi wrote:
> R CMD build does not actually run any R code,
**unless** the package contains dynamic vignettes and/or dynamic man
pages (e.g. man pages that include \Sexpr macros), in which case 'R CMD
build' first installs the package in order to evaluate the dynamic st
R CMD build does not actually run any R code, it just puts the files
together into a .tar.gz archive.
R CMD INSTALL will run the R code, and fail.
Gabor
On Sat, Jan 25, 2020 at 4:59 PM Andy Manka wrote:
>
>
> If you start a function in one file but don't close it, the package
> will still build
Try R check or the source function:
(From R check)
> R CMD check testpkg
R CMD check testpkg
* using log directory 'c:/proj/shared/testpkg.Rcheck'
* using R version 3.6.0 (2019-04-26)
* using platform: x86_64-w64-mingw32 (64-bit)
* using session charset: ISO8859-1
* checking for file 'testpk
If you start a function in one file but don't close it, the package
will still build if you manage to close it in a later file. Like so:
a.R
b.R
c.R
a.R:
function_a <- function(){
print("this is function_a")
}
b.R:
function_b <- function(){
print("unclosed function_b")
# no closing }
c.R: