workflowr / workflowr/workflowr
HTTPS authentication with GitHub will require a Personal Accesss Token
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 906
- Forks
- 107
- PR merge metrics
- No merged PRs in 30d
Description
https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/
It's unclear to me what the best course of action is. Some thoughts:
-
We already use the OAuth flow to authenticate with the GitHub API with
wflow_use_github()when creating a new GitHub repository. But this is a one-time operation, and the token is purposefully immediately discarded (so that there is no security leak). If we updatewflow_git_push()/wflow_git_pull()to use the OAuth flow, this would get tedious. And for security reasons, I don't really want workflowr to venture into managing tokens. -
git2r has a work-in-progress PR https://github.com/ropensci/git2r/pull/422 to use the credentials package. This would enable git2r to access the same PAT used by command-line Git. This would be convenient, but we'd still need a way for users to create the PAT in the first place. Many workflowr users are first-time Git users, so we can't assume they already have a PAT available. The usethis package has an entire vignette on GitHub authentication. Their current instructions are 1) create a PAT with
usethis::create_github_token()(unfortunately this is a manual step, it only opens the browser to the page), 2) save the PAT to the Git credentials store withgitcreds::gitcreds_set(). I wish this could be more automated, but I'm not sure if that is possible (or advisable).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review wflow_use_github(), wflow_git_push(), and wflow_git_pull() to understand the current OAuth and Git authentication paths. Read the linked git2r credentials work and the referenced usethis GitHub authentication vignette before deciding on the supported flow. Done requires an agreed approach for HTTPS authentication and documented behavior for first-time GitHub users.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- git, github, r
- Domain
- authentication, devops
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100