Description Usage Arguments Details Value Turning off package checks
Run R CMD check from R programmatically, and capture the results of the individual checks.
Runs R CMD check
as an external command, and parses its output and
returns the check failures.
1 2 3 4 5 6 7 8 9 10 11 12 13 |
path |
Path to a package tarball or a directory. |
quiet |
Whether to print check output during checking. |
args |
Character vector of arguments to pass to |
build_args |
Character vector of arguments to pass to |
check_dir |
Path to a directory where the check is performed.
If this is not |
libpath |
The library path to set for the check. The default uses the current library path. |
repos |
The |
timeout |
Timeout for the check, in seconds, or as a
base::difftime object. If it is not finished before this, it will be
killed. |
error_on |
Whether to throw an error on |
env |
A named character vector, extra environment variables to set in the check process. |
See rcmdcheck_process if you need to run R CMD check
in a background
process.
An S3 object (list) with fields errors
,
warnings
and notes
. These are all character
vectors containing the output for the failed check.
Sometimes it is useful to programmatically turn off some checks that may report check NOTEs. rcmdcehck provides two ways to do this.
First, you may declare in DESCRIPTION
that you don't want to see
NOTEs that are accepted on CRAN, with this entry:
1 | Config/rcmdcheck/ignore-inconsequential-notes: true
|
Currently, this will make rcmdcheck ignore the following notes:
report large package sizes (_R_CHECK_PKG_SIZES_ = FALSE
),
check cross-references in Rd files (_R_CHECK_RD_XREFS_ = FALSE
),
NOTE if package requires GNU make (_R_CHECK_CRAN_INCOMING_NOTE_GNU_MAKE_ = FALSE
),
report marked non-ASCII strings in datasets (_R_CHECK_PACKAGE_DATASETS_SUPPRESS_NOTES_ = TRUE
).
The second way is more flexible, and lets you turn off individual checks
via setting environment variables.
You may provide a tools/check.env
environment file in your package
with the list of environment variable settings that rcmdcheck will
automatically use when checking the package.
See Startup for the format of this file.
Here is an example tools/check.env
file:
1 2 3 4 5 6 7 8 9 10 11 | # Report if package size is larger than 10 megabytes
_R_CHECK_PKG_SIZES_THRESHOLD_=10
# Do not check Rd cross references
_R_CHECK_RD_XREFS_=false
# Do not report if package requires GNU make
_R_CHECK_CRAN_INCOMING_NOTE_GNU_MAKE_=false
# Do not check non-ASCII strings in datasets
_R_CHECK_PACKAGE_DATASETS_SUPPRESS_NOTES_=true
|
See the "R internals" manual and the R source code for the environment variables that control the checks.
Note that Config/rcmdcheck/ignore-inconsequential-notes
and the
check.env
file are only supported by rcmdcheck, and running
R CMD check
from a shell (or GUI) will not use them.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.