GitHub connectivity #214
Organizing various thoughts and issues around GitHub. Won't all be completed in v1.2.0 but this should make it easier to discuss and plan.
You = the usethis user
How usethis functions help to make the necessary connections:
The text was updated successfully, but these errors were encountered:
@jennybc Thanks for tackling this. Love the diagrams, but actually I think my use case isn't covered in these pictures. I don't think I'm crazy because my use-case is exactly what https://classroom.github.com does already, but maybe I'm missing something.
Essentially, I want to go from box 1 to box 1 (or equivalently, box 2 to box 2). The reason this doesn't fit into the diagram is that the diagram assumes that repository name is fixed; it let's you change where the repo lives, but it doesn't permit making copies of the repo with different names.
For instance, I have this repo called espm-157/climate-template. I want every student to end up with a repo called
Does that make sense?
I think this would look something like:
But this call to
In my ideal world, commands following
No, there's no way to do this in the GitHub API. My understanding is that was a major reason why GitHub Classroom was created in the first place, it provides a web API to do exactly this (and little else).
BTW, I just noticed
OK I've really read this now. Yes, let's keep hammering it out ... but after today's release. You want a few things that are not trivial: the copy-that's-not-a-fork, repo name flexibility, and remote handling.
As for your
Thanks, sounds like a plan!
It occurs to me that
* Strong, clear words about PAT; introduce new args * Add rationalize_fork() * Major upgrade of create_from_github() Fixes #215, Fixes #214 * Clones from the ssh or https url (vs the git url), which stores the correct URL for origin remote * Better logic re: forking * Adds upstream remote in case of fork * Allows token, credentials, host to be specified * Record some of my manual testing * Fail early if repo_path exists and is not empty In particular, do this before creating a fork * Use pat vs. falling back to env vars * Simplify logic when fork = NA * Work on docs re: github