I tried to install a package but face error when when
.
> checking files in 'vignettes' ... NOTE
The following directory looks like a leftover from 'knitr':
'figure'
Please remove from your package.
0 errors v | 3 warnings x | 2 notes x
Error: R CMD check found WARNINGs
Execution halted
Exited with status 1.
Refer to the solution via Leftovers from knitr as showing below but not helps.
One solution is to put
figure$ cache$
in a
.Rbuildignore
file in the main package directory. This only works if youR CMD check
on a built tarball rather than on the package source directory, but that's recommended as best practice anyway ... and it's effectively (I think) what the "Check" button in RStudio does, i.e. callingdevtools::check
, which automatically builds and checks a source package, using all known best practices.