Consider use_repo_template function? #109
usethis has great utilities for setting up a vanilla template using
But this twitter thread got me thinking: often rather start with my own template: don't have to enter my name, choose my usual license, and other tweaks. Moreover, sometimes my template isn't a package, but a more minimal project repo; or maybe it's a specific template for some classroom assignment I want students to use.
It would be nice to have a function to deploy some existing template repo. e.g. this is basically what GitHub forking does, without creating the 'fork' connection, and allowing a new repo name. (Similar also to what GitHub Classroom does, but that's bound to a single organization destination).
I think this would be a straight-forward wrapper around existing
Thanks for your thoughts.
The text was updated successfully, but these errors were encountered:
@jennybc bought this up too. To me, the big question is whether usethis should support template customisation/composition with files or with functions?
(But even then having
However, it doesn't seem to handle the case I am most interested in, where it could take a new name for the repo rather than creating a github fork, e.g., something like:
create_from_github("cboettig/template", destination = "cboettig/my-paper")
GitHub's forking buttons already make getting a copy of a repo with the same name as the parent easy, but getting a copy with a different name requires more git commands than can be done in RStudio git gui. (For instance, I wish my students could run:
Also noticed a few minor issues:
since it can get
Second, looks like you use
Sorry if I'm missing something obvious, but I don't think
Will open other issues for the minor things, thanks!