diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 643eafe..f2a61dc 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -52,5 +52,5 @@ touch packages/[r_package_name]/test.R ```bash make test-xenial-[r_package_name] -make test-bionic-[r_package_name] +make test-focal-[r_package_name] ``` diff --git a/packages/magick/install b/packages/magick/install index 447a46c..3b1cc53 100755 --- a/packages/magick/install +++ b/packages/magick/install @@ -16,3 +16,12 @@ if [ ${OS_CODENAME} == "xenial" ]; then fi apt-get install -y libmagick++-dev + + +if [ ${OS_CODENAME} == "focal" ]; then + # Enable imagemagick ghostscript features + # See https://www.kb.cert.org/vuls/id/332928/ + # focal has a new enough version of ghostscript + sed -i "\$i \ \ " /etc/ImageMagick-6/policy.xml +fi + diff --git a/packages/magick/test.R b/packages/magick/test.R index 9d4c569..23823f0 100644 --- a/packages/magick/test.R +++ b/packages/magick/test.R @@ -5,3 +5,11 @@ install.packages("magick", repos = "https://cran.rstudio.com") library(magick) docdir <- Sys.getenv("R_DOC_DIR", R.home("doc")) img <- magick::image_read(file.path(docdir, "html", "logo.jpg")) + +# Create a pdf +image_write(wizard, + tempfile(pattern = "pdftemp", fileext = '.pdf'), + density = 55, + format = 'pdf', + comment = "Edit PDFs and Images" +)