Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Function to do the remote rename dance #649

Closed
jimhester opened this issue Mar 10, 2019 · 2 comments
Closed

Function to do the remote rename dance #649

jimhester opened this issue Mar 10, 2019 · 2 comments
Assignees
Labels
feature a feature request or enhancement git git, GitHub, and CI in general
Milestone

Comments

@jimhester
Copy link
Member

jimhester commented Mar 10, 2019

When people first start contributing to a package one of the first major roadblocks is they likely have cloned the repo from the initial repo rather than from a fork. So they have to

  1. rename the origin remote to upstream then add the new remote as origin
  2. or burn it all down and re-clone from their fork, then add the origin as upstream later.

As far as I know there is no real way to do either step without needing command line git or something like Sourcetree, so it ends up being a pretty big hurdle for new contributors.

@hadley hadley added feature a feature request or enhancement git git, GitHub, and CI in general labels Mar 17, 2019
@hadley
Copy link
Member

hadley commented Mar 17, 2019

I think we should probably test for this situation in pr_init(), and if in an interactive environment, offer to resolve it automatically.

@jennybc jennybc self-assigned this Mar 28, 2019
@jennybc jennybc modified the milestones: v1.5.0, Backlog Mar 28, 2019
jennybc added a commit that referenced this issue Mar 31, 2019
jennybc added a commit that referenced this issue Mar 31, 2019
jennybc added a commit that referenced this issue Mar 31, 2019
* pkgdown-driven tweaks

* Add/export helpers around git remotes

Fixes #649

* Document the "remote rename dance"

* Add example of adding upstream remote

* Add test

* Add NEWS bullet

* pkgdown, add example, document()
@jennybc
Copy link
Member

jennybc commented Mar 31, 2019

use_git_remote() now makes this possible within R and the "remote rename dance" is one of the examples. It's possible we'll even provide more support in a hypothetical "unbork my fork" function (#618 Undo commits to a fork's master branch).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature a feature request or enhancement git git, GitHub, and CI in general
Projects
None yet
Development

No branches or pull requests

3 participants