Closed annakrystalli closed 4 years ago
Thanks for spotting this, it could be that use_git_config()
changed recently so it 'invisibly' returns nothing. Here's a discussion on the usethis repo: https://github.com/r-lib/usethis/issues/668 and where it was documented in a vignette: https://github.com/r-lib/usethis/blob/f08ecb6480310edd0e1c9b24e1d55359056804ec/vignettes/articles/usethis-setup.Rmd#L72-L73
Seems like use_git_config()
is now an unexported function in the usethis pkg, so we can update rrtools::create_compendium
with usethis:::git_config_get("user.name", global = TRUE)
to fix this.
Please wait for some discussion of your report before making a Pull Request.
Describe the bug
use_git_config()
no longer seems to return theuser.name
anduser.email
. As such, when runningcreate_compendium()
, the name inLICENSE
andlicense.md
is not correctly populated (ie is completely missing).To Reproduce
rrtools::create_compendium("~/Desktop/rrcompendium")
Expected behavior
Perhaps trying to infer the name from option
usethis.fullname
would be better and if not possible, to either pause and prompt users to enter a name interactively during initialisation or throw a warning at the end to inform users that the name is missing in the license and needs completing manually.