Skip to content
Prev 6098 / 12125 Next

[R-pkg-devel] is R CMD build --compact-vignettes working as expected?

Huh, weird. "both" worked for me.

   My debugging process involved instrumenting the compression function 
to report what it was doing (see below), rebuilding R, and running the 
build and check --as-cran processes again. (If the package you're 
experiencing problems with is public, feel free to point me to it and 
I'll try to take a look.)

   cheers
    Ben

Index: src/library/tools/R/admin.R
===================================================================
--- src/library/tools/R/admin.R	(revision 79311)
+++ src/library/tools/R/admin.R	(working copy)
@@ -1088,6 +1088,7 @@
          }
          if(!res && file.exists(tf)) {
              old <- file.size(p); new <-  file.size(tf)
+            cat(sprintf("compression: old=%f, new=%f, new/old=%f, 
old-new=%f",old, new, new/old,old-new),"\n")
              if(new/old < 0.9 && new < old - 1e4) {
                  file.copy(tf, p, overwrite = TRUE)
                  ans[p, ] <- c(old, new)
On 10/8/20 11:10 AM, John Fox wrote: