Note: I cross-posted this question here: https://github.com/hadley/devtools/issues/245
Update: @hadley just closed the issue since he can install now. I have tested it just now and install_github
works on Windows too. Apparently I need wait for some time for Github archive to include the new committed changes. For people encounter the same problem, @hadley pointed out that I have .R and .r files in R/ and all the files in DESCRIPTION collate have .r extensions.
I am writing an R package and put it on Github. I can build and load on my own computer. However, after running install_github("KineticEval",username="zhenglei-gao")
, I got the following error:
* installing *source* package 'KineticEval' ...
** R
Error in .install_package_code_files(".", instdir) :
files in 'Collate' field missing from 'C:/Users/z.gao/AppData/Local/Temp/RtmpUzWWYn /R.INSTALLd3c17515a0/KineticEval/R':
kingraph.r
kinplot.r
FOCUS2006A.r
FOCUS2006B.r
FOCUS2006C.r
FOCUS2006D.r
modFit1.r
IRLSkinfit.full.r
mkinfit.full.r
ERROR: unable to collate and parse R files for package 'KineticEval'
* removing 'C:/Users/z.gao/R-dev/KineticEval'
A related question is here: Files in Collate field missing from package after build from incorrect .Rbuildignore file
But I can't figure out whether the error is also related to my .Rbuildignore file.
roxygen2
to generate the Collate field. – Sewardroxygenize
is executed beforeR CMD INSTALL
– Yannroxygenize
and push it to Github, then try to useinstall_github()
which automatically runsR CMD INSTALL
. I can runR CMD INSTALL
andinstall()
without using the Github repository but my own repository. – Sewardgit clone
a clean repository first. Runroxygenize
on the cloned repository. Rungit status
to check if any files are modified. – Yann