查看原文
其他

你只有一个系统,却要在多个平台上测试你的R包

Y叔叔 YuLabSMU 2022-09-20

做为开发者,你必须是R CMD check经常跑的,但你只有一个平台,这就不好搞了,当然你可以用Travis (Linux, macOS) 或 Appveyor (Windows),但是有更好的方法,你根本就不用离开你的R,不管你是那个系统下,你都可以将R CMD check跑在各种其它的系统上,然后就像在你自己的机器上跑一样,实时看到输出,检查是否那里有问题。

chk <- check_for_cran()# wait a bitchk$cran_summary()#> Updating status...#> ## Test environments#> - R-hub fedora-clang-devel (r-devel)#> - R-hub windows-x86_64-devel (r-devel)#> - R-hub ubuntu-gcc-release (r-release)#> #> ## R CMD check results#> ❯ On fedora-clang-devel (r-devel), windows-x86_64-devel (r-devel), ubuntu-gcc-release (r-release)#> checking CRAN incoming feasibility ... NOTE#>   Maintainer: ‘Maëlle Salmon <maelle.salmon@yahoo.se>’#> #> New submission#> #> The Description field contains#>     <http://http://cran.r-project.org/doc/manuals/r-release/R-exts.html#The-DESCRIPTION-file>#> Please enclose URLs in angle brackets (<...>).#> #> The Date field is over a month old.#> #> ❯ On fedora-clang-devel (r-devel), windows-x86_64-devel (r-devel), ubuntu-gcc-release (r-release)#> checking R code for possible problems ... NOTE#>   .bello: no visible global function definition for ‘tail’#>   Undefined global functions or variables:#> tail#> Consider adding#> importFrom("utils", "tail")#> to your NAMESPACE file.#> #> 0 errors ✔ | 0 warnings ✔ | 2 notes ✖


支持各种平台,已经发行版和开发版的R

namedescriptioncran-name
debian-gcc-develDebian Linux, R-devel, GCCr-devel-linux-x86_64-debian-gcc
debian-gcc-patchedDebian Linux, R-patched, GCCr-patched-linux-x86_64
debian-gcc-releaseDebian Linux, R-release, GCCr-release-linux-x86_64
fedora-clang-develFedora Linux, R-devel, clang, gfortranr-devel-linux-x86_64-fedora-clang
fedora-gcc-develFedora Linux, R-devel, GCCr-devel-linux-x86_64-fedora-gcc
linux-x86_64-centos6-epelCentOS 6, stock R from EPELr-release
linux-x86_64-centos6-epel-rdtCentOS 6 with Redhat Developer Toolset, R from EPELr-release
linux-x86_64-rocker-gcc-sanDebian Linux, R-devel, GCC ASAN/UBSANr-devel
macos-elcapitan-releasemacOS 10.11 El Capitan, R-release (experimental)r-release-osx-x86_64
macos-mavericks-oldrelmacOS 10.9 Mavericks, R-oldrel (experimental)r-oldrel-osx-x86_64
solaris-x86-patchedOracle Solaris 10, x86, 32 bit, R-patched (experimental)r-patched-solaris-x86
ubuntu-gcc-develUbuntu Linux 16.04 LTS, R-devel, GCCr-devel
ubuntu-gcc-releaseUbuntu Linux 16.04 LTS, R-release, GCCr-release
ubuntu-rchkUbuntu Linux 16.04 LTS, R-devel with rchkr-devel
windows-x86_64-develWindows Server 2008 R2 SP1, R-devel, 32/64 bitr-devel
windows-x86_64-devel-rtools4Windows Server 2012, R-devel, Rtools4.0, 32/64 bit (experimental)r-devel
windows-x86_64-oldrelWindows Server 2008 R2 SP1, R-oldrel, 32/64 bitr-oldrel-windows-ix86+x86_64
windows-x86_64-patchedWindows Server 2008 R2 SP1, R-patched, 32/64 bitr-patched
windows-x86_64-releaseWindows Server 2008 R2 SP1, R-release, 32/64 bitr-release-windows-ix86+x86_64

免费,而且是开源的

rhub:https://github.com/r-hub/ 就是github上,它是开源的,而且服务是免费的。

其实还能有别的用处

早在三年前,《无中生有windows版R包》中,我已经演示了另一种rhub的用法,那就是使用这些平台来打R包,当年我只有MacLinux系统,然后我用rhub来生成Windows版本的R包,方便其他用户下载安装。


往期精彩

R里的赋值符号?再见joyplotCS2: BED文件一个要复活的R包和一个404的网站[连载2]:Editor你的心不会痛吗?[连载4]:我像是一颗棋,进退任由你决定s01 - Counting DNA Nucleotidesxlim_tree: set x axis limits for only Tree panel

您可能也对以下帖子感兴趣

文章有问题?点此查看未经处理的缓存