【发布时间】:2019-07-09 18:30:10
【问题描述】:
这里完全是新手,所以这里可能有一些非常糟糕的地方。我按照 Hadley Wickham 关于 R 包的书创建了一个项目,现在我正在尝试将其添加到 github 以进行远程安装 (repository for reference)。
运行devtools::install_github("alutterb/abcmlr") 生成以下输出:
Downloading GitHub repo alutterb/abcmlr@master
√ checking for file 'C:\Users\amlut\AppData\Local\Temp\RtmpMpn5uJ\remotes7146c405dd7\alutterb-abcmlr-918bf05/DESCRIPTION' ...
- preparing 'abcmlr':
√ checking DESCRIPTION meta-information ...
- checking for LF line-endings in source and make files and shell scripts
- checking for empty or unneeded directories
- building 'abcmlr_0.1.0.tar.gz'
Installing package into ‘C:/Users/amlut/Documents/R/win-library/3.5’
(as ‘lib’ is unspecified)
* installing *binary* package 'abcmlr' ...
cp: unknown option -- )
Try '/Rtools/bin/cp --help' for more information.
ERROR: installing binary package failed
* removing 'C:/Users/amlut/Documents/R/win-library/3.5/abcmlr'
In R CMD INSTALL
Error in i.p(...) :
(converted from warning) installation of package ‘C:/Users/amlut/AppData/Local/Temp/RtmpMpn5uJ/file71463953e7b/abcmlr_0.1.0.tar.gz’ had non-zero exit status
在我的存储库中,我有一个与wsl 一起使用的Linux 可执行文件,以及一个在我的R 代码中调用的.exe 文件。这些可能是罪魁祸首,但我并不完全确定。该错误指出它无法安装二进制包,但install_github() 需要一个源包,所以我不确定发生了什么。任何帮助表示赞赏。
谢谢。
编辑:这个问题解决了。这是因为我的DESCRIPTION 文件中有一行与Built 有关。
【问题讨论】: