You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However it failed:
Despite having correctly setup the git configuration, see the git_sitrep:
The problem comes from use_github, which expects to find a branch. But the branch is not created in use_git because Rstudio already created the repository and then use_git doesn't continue and commit the "Initial commit".
A solution would be to check if there is any committed file by checking the repository head. This involves the line
TLDR:Use_git doesn't make the initial commit if the project is started already with git from Rstudio
I started a new package following the Rstudio new project > R package > git then I used some of the
usethis
functions to set up the package.The history of command run is:
However it failed:


Despite having correctly setup the git configuration, see the
git_sitrep
:The problem comes from
use_github
, which expects to find a branch. But the branch is not created inuse_git
because Rstudio already created the repository and thenuse_git
doesn't continue and commit the "Initial commit".A solution would be to check if there is any committed file by checking the repository head. This involves the line
usethis/R/git.R
Line 14 in 9ffc27f
Which could be adapted to check if there is any committed file or any branch.
The text was updated successfully, but these errors were encountered: