From kry|ov@r00t @end|ng |rom gm@||@com  Mon Oct  2 13:58:09 2023
From: kry|ov@r00t @end|ng |rom gm@||@com (Ivan Krylov)
Date: Mon, 2 Oct 2023 14:58:09 +0300
Subject: [Rd] [R-pkg-devel] Problem with "compacting" pdf files.
In-Reply-To: <20231002100113.2ce1c902@rolf-Latitude-E7470>
References: <20231001211547.4c46512e@rolf-Latitude-E7470>
 <20231001152234.6bdd40ec@Tarkus>
 <20231002100113.2ce1c902@rolf-Latitude-E7470>
Message-ID: <20231002145809.41884ebc@arachnoid>

Dear Rolf,

(Moving this one to R-devel...)

On Sun,  1 Oct 2023 21:01:13 +0000
Rolf Turner <rolfturner at posteo.net> wrote:

> I *really* think that the instructions from CRAN could have been
> clearer!  Without your guidance I'd have been at a total loss.

Since the CRAN e-mails quote the R CMD check messages verbatim, would
it have been enough if R CMD check suggested using --compact-vignettes?

Index: src/library/tools/R/check.R
===================================================================
--- src/library/tools/R/check.R	(revision 85249)
+++ src/library/tools/R/check.R	(working copy)
@@ -3079,7 +3079,8 @@
                          "  'qpdf' made some significant size reductions:\n",
                          paste("  ", res, collapse = "\n"),
                          "\n",
-                         "  consider running tools::compactPDF() on these files\n")
+                         "  consider running tools::compactPDF() on these files,\n",
+                         "  or build the source package with --compact-vignettes\n")
             }
             if (R_check_doc_sizes2) {
                 gs_cmd <- find_gs_cmd()
@@ -3093,7 +3094,8 @@
                                  "  'gs+qpdf' made some significant size reductions:\n",
                                  paste("  ", res, collapse = "\n"),
                                  "\n",
-                                 '  consider running tools::compactPDF(gs_quality = "ebook") on these files\n')
+                                 '  consider running tools::compactPDF(gs_quality = "ebook") on these files,\n',
+                                 '  or build the source package with --compact-vignettes=both\n')
                     }
                 } else {
                     if (!any) noteLog(Log)

Or is there anything else you would prefer to be reworded? Should the
message link to Writing R Extensions, section 1.4? Recently there was a
project to improve the R CMD check messages [*], but I managed to miss
almost all of it.

-- 
Best regards,
Ivan

[*] https://github.com/r-devel/r-project-sprint-2023/issues/55



[Rd] [R-pkg-devel] Problem with "compacting" pdf files.
Ivan Krylov