Ivan, thank you for the tips; they allowed me to move on to the next problems.
By building the tar file first and checking it later, and fixing several other 
problems I got
R CMD check to work.  It does *not* delete inst/doc.  It also does not run 
boostrap.R,
as far as I can tell, presumably because only devtools does.

Check within RStudio continues to delete inst/doc, so this behavior is probably 
coming from
RStudio, devtools, or one the packages it invokes.  The devtools::check() 
documentation
mentions it invoke pkgbuild::build() and rcmdcheck::rcmdcheck().  Since I'm 
guessing my command
line build and check invoked those last 2, or at least operated similarly, they 
seem less likely suspects.

As I think I already mentioned, bootstrap.R when run outside of a check, but 
inside RStudio, also does not delete inst/doc.

Anyway, there a lot of moving parts.  Does anybody have any ideas?  Deleting 
the directory just seems weird and so it's hard
to know where to look.

Thanks.
Ross

-----Original Message-----
From: Ivan Krylov <ikry...@disroot.org> 
Sent: Friday, May 3, 2024 12:52 PM
To: Boylan, Ross via R-help <r-help@r-project.org>
Cc: Boylan, Ross <ross.boy...@ucsf.edu>
Subject: Re: [R] R CMD check vs RStudio check

В Fri, 3 May 2024 19:45:08 +0000
"Boylan, Ross via R-help" <r-help@r-project.org> пишет:

> & $R CMD check .

> * checking for file './DESCRIPTION' ... ERROR Required fields missing 
> or empty:
>   'Author' 'Maintainer'

You're checking a source package directory. This could work, but it's much 
easier and more reliable to (1) build a source tarball using R CMD build and 
(2) check the tarball. This is probably part of what
devtools::check() does. (It can also do a lot of other things pre-R CMD
build.)

The reason checking the source directory is failing is because it's R CMD build 
that creates the necessary 'Author' and 'Maintainer' fields from Authors@R in 
your DESCRIPTION.

> P.S. What's with the "..Rcheck" log directory, which appears literally 
> with the 2 dots?  Is this just MS-Windows getting confused and not 
> interpreting .. as the parent directory?

"..Rcheck" is built from the argument of R CMD check . followed by ".Rcheck".

--
Best regards,
Ivan
______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to