pdb
pdb

Reputation: 1677

R CMD build fails to ignore vignette referenced in .Rbuildignore

I have a vignette that I want to exclude from a build. Yes, I could delete it, but I think .Rbuildignore is supposed to help me here. I referenced the file in .Rbuildignore and it does not end up in the package. However, R CMD check gives a warning:

 * checking 'build' directory ... WARNING
 Output(s) listed in 'build/vignette.rds' but not in package:
   'inst/doc/ignoreMe.pdf'

Here is a related question R CMD build skips knitr/Rmd vignettes - "Output(s) listed in 'build/vignette.rds' but not in package" only, I wanted the vignette ignored (and for it to not generate a warning when it is ignored). Is that possible?

This does not appear to be mentioned in the Writing R Extensions index link to .Rbuildignore.

Why would I want to do this? My development cycle has version n getting polished off while version n+1 is in the works. This vignette is part of n+1 and .Rbuildignore helps me exclude everything else from that version.

Upvotes: 6

Views: 788

Answers (2)

pdb
pdb

Reputation: 1677

This turned out to be a bug in R. It is claimed to be fixed in R 3.4.1. see bugs.r-project.org/bugzilla3/show_bug.cgi?id=17246.

Upvotes: 1

Claudia
Claudia

Reputation: 1016

I had the same problem and I sorted it by removing the VignetteBuilder argument from the DESCRIPTION file. Not sure if this is also your case.

Upvotes: 2

Related Questions